You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Jody Grassel (JIRA)" <ji...@apache.org> on 2010/12/10 22:39:00 UTC

[jira] Created: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
---------------------------------------------------------------------------------------------------------------

                 Key: OPENJPA-1905
                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
             Project: OpenJPA
          Issue Type: Bug
          Components: usability, validation
    Affects Versions: 2.0.1, 2.0.0, 1.2.2, 1.2.1, 1.2.0
            Reporter: Jody Grassel
            Assignee: Jody Grassel
            Priority: Minor


While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.

However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.

Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Dick reopened OPENJPA-1905:
-----------------------------------


Reopening to make sure we don't lose track of this for 2.0.x.

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>             Fix For: 1.2.3, 2.0.2, 2.1.0, 2.2.0
>
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Dick updated OPENJPA-1905:
----------------------------------

    Fix Version/s: 2.2.0

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>             Fix For: 1.2.3, 2.0.2, 2.1.0, 2.2.0
>
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Jody Grassel (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jody Grassel closed OPENJPA-1905.
---------------------------------

    Resolution: Fixed

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>             Fix For: 1.2.3, 2.0.2, 2.1.0, 2.2.0
>
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Work started: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Jody Grassel (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Work on OPENJPA-1905 started by Jody Grassel.

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Dick updated OPENJPA-1905:
----------------------------------

    Fix Version/s: 2.1.0
                   2.0.2
                   1.2.3

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>             Fix For: 1.2.3, 2.0.2, 2.1.0
>
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (OPENJPA-1905) jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Dick resolved OPENJPA-1905.
-----------------------------------

    Resolution: Fixed

If there's more work to be done for this issue please re-open, or open a sub task for the remaining work. 

> jar-file validation should be deferred until after OpenJPA is confirmed to be the application's chosen provider
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1905
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1905
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: usability, validation
>    Affects Versions: 1.2.0, 1.2.1, 1.2.2, 2.0.0, 2.0.1
>            Reporter: Jody Grassel
>            Assignee: Jody Grassel
>            Priority: Minor
>             Fix For: 1.2.3, 2.0.2, 2.1.0
>
>
> While processing a persistence-unit definition in persistence.xml requested by an invocation of PersistenceProvider.createEntityManagerFactory(), validation of elements such as <jar-file> take place during the execution of the SAXParser.  If an entry named by the element does not exist, a GeneralException originating from the SAXException fails the createEMF() operation -- the expected and correct behavior in such a situation.
> However, this validation occurs before OpenJPA checks to see if it is the JPA Provider requested by the Application.  This means that OpenJPA throws this Exception regardless to the fact that the PU may have defined a <persistence> element requesting a JPA provider other then OpenJPA -- instead of returning the expected null value as expected by the contract.
> Thus, there needs to be a change where the first item validated is the requested provider, immediately returning null as per JPA Spec contract if OpenJPA is not the requested provider.  This would cause the error in the scenario described above to be reported by the requested JPA provider, instead of short-circuiting the process as can happen currently.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.