This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 225571 - Wrong libraries
Summary: Wrong libraries
Status: RESOLVED INVALID
Alias: None
Product: javaee
Classification: Unclassified
Component: Persistence (show other bugs)
Version: 7.4
Hardware: PC All
: P1 normal (vote)
Assignee: Sergey Petrov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-31 06:37 UTC by Chiana
Modified: 2013-01-31 11:10 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chiana 2013-01-31 06:37:47 UTC
[ BUILD # : 20130130 ]
[ JDK VERSION : 1.7.0_09 ]

I noted that EJB3-persistence unit is replaced with "Persistence - hibernate -
jpa - 2.0..." and those libriaries are not compatible with EJB3.
As I'm writing a new persistenceprovider to replace hibernate it actually broke
my code, and besides replacing a core library with a third-party is never a
good idea.
This is a regression from 20130126 witch has the correct libraries.
Comment 1 Sergey Petrov 2013-01-31 10:05:15 UTC
It's unclear what is wrong.
Persistence was a part of hibernate JPA 1.0 API and in 7.3.1 its replaced with new hibernate library with JPA2.0 api, no JPA 1.0 api is bundled with nb any more. We can't keep it forever, what is the issue here?
Comment 2 Sergey Petrov 2013-01-31 10:06:15 UTC
If you need any library isn't bundled with nb you can always create it yourself.
Comment 3 Sergey Petrov 2013-01-31 10:09:41 UTC
and it's not part of 7.3 also (regarding version) it's part of nb next
Comment 4 Chiana 2013-01-31 10:23:48 UTC
Then were are the correct libraries? According to http://docs.oracle.com/javaee/5/api/javax/persistence/spi/PersistenceProvider.html they should be there... The libraries with netbeans does not conform to that.
Comment 5 Sergey Petrov 2013-01-31 10:28:19 UTC
yes, nb next will contain separate api for ee6/jpa2.0 derived from hibernate(but may be hbernate can be dropped in lib name) and api for ee7/jpa2.1 as part of eclipselink. no ee5/jpa1.0 library. If you need ee5 level, you'll need to download ee5/jpa1.0 api jar and create a library.

But do you mean there is no PersistenceProvider in supplied @Persistence - hibernate -
jpa - 2.0...@?
Comment 6 Chiana 2013-01-31 10:30:11 UTC
No, just that it does not have the same signature, and that makes it non-backward compatible.
Comment 7 Sergey Petrov 2013-01-31 10:35:48 UTC
yes, jpa 1 provider should work in jpa 2 environment but backward compatibility isn't provided, it seems ok. If you really want to create jpa1.0 provider with next nb which will be released not sure when but likely after ee7 will be already released, you have to use your own api jar instead of bundled one.
Comment 8 Chiana 2013-01-31 10:50:23 UTC
May be so, but IMHO there still should have been @Deprecated and created new interfaces for ee6+ instead of just replacing them without notice
Comment 9 Sergey Petrov 2013-01-31 11:10:13 UTC
It's 3-4 clicks to create your own library with the same jars (except jars downloading) (it's on nb side). regarding api changes in 1.0->2.0 I have no comments why it was done this way or another way.