This is an automated email from the ASF dual-hosted git repository.

zregvart pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/master by this push:
     new 97f67e3  CAMEL-13336: fix broken JPA XSD schema
97f67e3 is described below

commit 97f67e3b64679169475b5e548c15cd932e44c1c1
Author: Zoran Regvart <zregv...@apache.org>
AuthorDate: Tue Mar 19 14:06:15 2019 +0100

    CAMEL-13336: fix broken JPA XSD schema
    
    Also makes sure that we don't break it again using the license plugin.
---
 .../test/resources/META-INF/persistence_2_1.xsd    | 81 +++++++++++++++++-----
 pom.xml                                            |  1 +
 2 files changed, 66 insertions(+), 16 deletions(-)

diff --git 
a/components/camel-jpa/src/test/resources/META-INF/persistence_2_1.xsd 
b/components/camel-jpa/src/test/resources/META-INF/persistence_2_1.xsd
index dd4786c..01d5149 100644
--- a/components/camel-jpa/src/test/resources/META-INF/persistence_2_1.xsd
+++ b/components/camel-jpa/src/test/resources/META-INF/persistence_2_1.xsd
@@ -1,22 +1,71 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-         http://www.apache.org/licenses/LICENSE-2.0
+<!-- persistence.xml schema -->
+<xsd:schema targetNamespace="http://xmlns.jcp.org/xml/ns/persistence"; 
+  xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+  xmlns:persistence="http://xmlns.jcp.org/xml/ns/persistence";
+  elementFormDefault="qualified" 
+  attributeFormDefault="unqualified" 
+  version="2.1">
+
+  <xsd:annotation>
+    <xsd:documentation>
+      @(#)persistence_2_1.xsd  2.1  February 4, 2013
+    </xsd:documentation>
+  </xsd:annotation>
+
+  <xsd:annotation>
+    <xsd:documentation>
+
+  Copyright (c) 2008  - 2013 Oracle Corporation. All rights reserved. 
+  
+  This program and the accompanying materials are made available under the 
+  terms of the Eclipse Public License v1.0 and Eclipse Distribution License v. 
1.0 
+  which accompanies this distribution. 
+  The Eclipse Public License is available at 
http://www.eclipse.org/legal/epl-v10.html
+  and the Eclipse Distribution License is available at 
+  http://www.eclipse.org/org/documents/edl-v10.php.
+  
+  Contributors:
+      Linda DeMichiel - Java Persistence 2.1, Version 2.1 (February 4, 2013)
+      Specification available from http://jcp.org/en/jsr/detail?id=338
+ 
+    </xsd:documentation>
+  </xsd:annotation>
+
+   <xsd:annotation>
+     <xsd:documentation><![CDATA[
+
+     This is the XML Schema for the persistence configuration file.
+     The file must be named "META-INF/persistence.xml" in the 
+     persistence archive.
+
+     Persistence configuration files must indicate
+     the persistence schema by using the persistence namespace:
+
+     http://xmlns.jcp.org/xml/ns/persistence
+
+     and indicate the version of the schema by
+     using the version element as shown below:
+
+      <persistence 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";
+        version="2.1">
+          ...
+      </persistence>
+
+    ]]></xsd:documentation>
+  </xsd:annotation>
+
+  <xsd:simpleType name="versionType">
+    <xsd:restriction base="xsd:token">
+      <xsd:pattern value="[0-9]+(\.[0-9]+)*"/>
+    </xsd:restriction>
+  </xsd:simpleType>
 
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
+  <!-- **************************************************** -->
 
--->
   <xsd:element name="persistence">
     <xsd:complexType>
       <xsd:sequence>
diff --git a/pom.xml b/pom.xml
index 8b6ed74..1696cc9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -776,6 +776,7 @@
                                 <exclude>**/*.txt</exclude>
                                 <exclude>.mvn/**</exclude>
                                 <exclude>mvnw*</exclude>
+                                <exclude>**/META-INF/persistence*.xsd</exclude>
                             </excludes>
                             <mapping>
                                 <java>SLASHSTAR_STYLE</java>

Reply via email to