persistence@glassfish.java.net

Re: findbugs and javax.persistence.Persistence

From: Marina Vatkina <Marina.Vatkina_at_Sun.COM>
Date: Tue, 14 Feb 2006 15:35:29 -0800

Hi Mike,

No, this is javax.persistence.Persistence, PersistenceProvider is in a different
package: javax.persistence.spi. But otherwise I agree with your assumptions.

thanks,
-marina

Mike Keith wrote:
> Hi Marina,
>
> The spec class is called javax.persistence.PersistenceProvider,
> but withouth looking at the code I suspect that this constant may
> have been used for some impl purpose, probably to store the provider
> at one point, and is no longer used.
>
> The providers member is not in the spec at all but I am guessing is
> an implementation artifact of the providers that the Persistence class
> found when it looked around using the services API.
>
> -Mike
>
>
>>-----Original Message-----
>>From: Marina Vatkina [mailto:Marina.Vatkina_at_Sun.COM]
>>Sent: Tuesday, February 14, 2006 4:35 PM
>>To: Mike Keith
>>Cc: Linda DeMichiel; persistence_at_glassfish.dev.java.net
>>Subject: findbugs and javax.persistence.Persistence
>>
>>
>>Mike, Linda,
>>
>>FindBugs tool reported the following 2 problems with
>>javax.persistence.Persistence:
>>
>>H V MS: javax.persistence.Persistence.PERSISTENCE_PROVIDER
>>isn't final but should be
>>H V MS: javax.persistence.Persistence.providers isn't final
>>but should be
>>
>>We also noticed that PERSISTENCE_PROVIDER is not used in
>>GlassFish and not
>>mentioned anywhere in the spec. Should it be removed?
>>
>>thanks,
>>-marina
>>
>>