This Question have no Text answers yet!

http://xmlns.jcp.org/xml/ns/persistence":persistence-unit}' is expected error when using restful webservice using netbeans

By : faraa
Source: Stackoverflow.com
Question!

I am deploying a restful webservice using jersey.I am reading this tutorial and doing instructions: http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/RESTfulWebServices/RESTfulWebservices.htm

but I get this error on deploying on server .

Severe: Exception while deploying the app [PlayerServer2] : org.xml.sax.SAXParseException; lineNumber: 5; columnNumber: 15; Deployment descriptor file META-INF/persistence.xml in archive [classes]. cvc-complex-type.2.4.b: The content of element 'persistence' is not complete. One of '{"http://xmlns.jcp.org/xml/ns/persistence":persistence-unit}' is expected.

I am using netbean 8.0.1, glassfish server 4.1, JDK 1.8.91, JPA 2.1

Edited:

persistence.xml

<persistence version="2.1" xmlns="http://xmlns.jcp.org/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd">
  <persistence-unit name="PlayerServer2PU" transaction-type="JTA">
    <jta-data-source>jdbc/playerdb2</jta-data-source>
    <exclude-unlisted-classes>false</exclude-unlisted-classes>
    <properties/>
  </persistence-unit>
</persistence>
By : faraa


Video about http://xmlns.jcp.org/xml/ns/persistence":persistence-unit}' is expected error when using restful webservice using netbeans