title: How to create JAXBContext in EclipseLink?
body: <p><code>JAXBContext.newInstance()</code> method receives <code>Map</code> with properties as a parameter.</p>
  
  <p>Which properties and how should I specify to make <code>JAXBContext</code> instance informed about several files with xml-mappings? </p>
  
  <p><a href="http://bdoughan.blogspot.com/2010/12/extending-jaxb-representing-annotations.html" rel="nofollow">Example</a> shows how to specify only one file in a way which is not acceptable in real systems (i.e. with <code>new File(address)</code>). Instead of this I need to use <code>classLoader.getResource()</code> which returns <code>URL</code> object. </p>
  
  <p>Thanks!</p>
  
  <p>UPD:</p>
  
  <p>When I try to instantiate JAXBContext I get this exeption: </p>
  
  <pre><code>javax.xml.bind.JAXBException: property "eclipselink-oxm-xml" is not supported
      at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:118)
      ...
  </code></pre>
  
  <p>It's obvious that <code>jaxb.properties</code> file is not found at start up. Where should I put it? (I'm using maven, and actually I've tried to put it to <code>/target/jaxb.properties</code>, <code>/target/classes/jaxb.properties</code>, <code>/target/classes/META-INF/definitions/jaxb.properties</code> - it's near xml-mapping file, and <code>/target/classes/com/myproject/experiment/jaxb.properties</code> - it's near the class which tries to instantiate JAXBContext).</p>