I have JAXB objects created from a schema. While marshalling, the xml elements are getting annotated with ns2. I have tried all the options that exist over the net for this
I got the working result by the setting the property:
marshaller.setProperty(Marshaller.JAXB_SCHEMA_LOCATION, "");