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.
Summary: | Module classpath isolation | ||
---|---|---|---|
Product: | platform | Reporter: | Peter Nabbefeld <epdv> |
Component: | Module System | Assignee: | Tomas Hurka <thurka> |
Status: | REOPENED --- | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | 8.2 | ||
Hardware: | PC | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: |
Sample project
New Sample Project IDE Log from testing environment |
Description
Peter Nabbefeld
2016-11-24 05:37:48 UTC
Can you please attach sample project, which demonstrates this problem. Thanks. Created attachment 163062 [details]
Sample project
Well, the structure of the sample project is incorrect, too, but sufficient to show the problem.
To see the problem, You must have activated JEE, as this brings up JPA from EclipseLink and Hibernate, which cause conflicts beetween those and also with "my" private JPA, in this case DataNucleus.
Without JEE, You'll get a ClassNotFoundException, which is another problem with module classpaths (I'll need to pack my entity classes into the same module as private JPA, as otherwise I'd need a circular dependency).
In the meantime, I've found this: OpenIDE-Module-Hide-Classpath-Packages: javax.lang.model.*, com.sun.source.** at: http://bits.netbeans.org/6.1/javadoc/org-openide-modules/overview-summary.html I'll go to investigate this further, if it helps to get the required behaviour. If yes, IMHO it would be a good idea to add some GUI for this feature to the project properties panel. I've found the sample project to be invalid, as DataNucleus needs an additional enhancement step, which I've noticed too late, sorry. I wanted to use some JPA not existant in NetBeans, just to work around my problems with duplicated classes. I'll try to use Hibernate together with "OpenIDE-Module-Hide-Classpath-Packages" now. Because I couldn't make sure if this will work or not up to now, I reduce priority for now. Depending on my results, I'll either raise priority again or close the issue. Created attachment 163127 [details]
New Sample Project
I've tried again now with Hibernate and hiding modules, still fails.
Created attachment 163128 [details]
IDE Log from testing environment
IDE Log from testing environment
Increasing priority again, as nothing seems to help. Please, steps to reproduce. I.e.: 1. Get the sample project attached to this issue. 2. Open it in NetBeans IDE 8.??? on windows? Mac? any of them? 3. Do... 4. The expected result is... 5. However, instead of that... Hi Geertjan, 1. Sample project already attached 2. As it concerns JPA, connection in persistence.xml has to be configured. "create" must be enabled first time. 3. Klick "Windows" -> "Try JPA write". 4. Expected: Tables created on first try. Next try "create" must be disabled. Nothing visible expected, as nothing is really written currently. 5. Currently, if no Java modules are enabled, this even works. 6. Enable Java SE, Java EE, Mod. Development (all those I'm enabling usually). 7. Now, an exception is thrown (see message log, already attached). Kind regards Peter |