[ 
https://issues.apache.org/jira/browse/OPENJPA-2976?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18106216#comment-18106216
 ] 

Maxim Solodovnik commented on OPENJPA-2976:
-------------------------------------------

According to https://jakarta.ee/xml/ns/persistence/ there is no version {{3.1}} 
for {{persistence.xsd}}

I can add following comment to the code:
{code}
                // VERSION_3_1 is validated against `persistence_3_0.xsd` due 
to 3.1 contains only changes to orm
                // thus persistence_3_0.xsd remain unchanged
{code}

or remove such a block all together

[~romain.manni-bucau] what option is preferred?

> version 3.1 persistence.xml validated against 3.0 XSD
> -----------------------------------------------------
>
>                 Key: OPENJPA-2976
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-2976
>             Project: OpenJPA
>          Issue Type: Sub-task
>          Components: jpa
>    Affects Versions: 4.2.0
>            Reporter: Maxim Solodovnik
>            Assignee: Maxim Solodovnik
>            Priority: Major
>             Fix For: 4.2.0
>
>
> Discussion thread: 
> https://github.com/apache/openjpa/pull/144#discussion_r3683004555
> **(medium)** Documents declaring `version="3.1"` are routed to 
> `persistence_3_0.xsd.rsrc`, but that schema declares `version` as 
> `fixed="3.0" use="required"`, so such documents always fail XSD validation - 
> and with the new SAX-rethrow logic at line 570 this now aborts unit discovery 
> instead of being skipped. Is the branch intentional, and should not it 
> validate against a schema that accepts "3.1"? (Note the copy-pasted 
> `PERSISTENCE_XSD_3_0` in the 3.1 condition.)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to