I could not figure out how to get JAXB to load my jaxb.index file. I tried placing in the same directory as the package's class files, but I was still getting an error. Furthermore, it seems that the schemagen task has all the information it needs to create either of these files automatically and in the right place so that the JAXB library could find them. For now, I have created a somewhat convoluted but successful build process whereby I generated an XSD using schemagen, generate java source files from the XSD in a temporary directory, and lastly, copy over the generated ObjectFactory.java file back to the original source tree to be used in compilation. Does anyone see any problems with this workaround? What do people think about making the automatica generation of ObjectFactory or jaxb.index an official option in the schemagen task?