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 178757 - warn user about usage of optional Java EE packages
Summary: warn user about usage of optional Java EE packages
Status: RESOLVED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 normal (vote)
Assignee: David Konecny
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-16 14:18 UTC by David Konecny
Modified: 2011-01-23 22:38 UTC (History)
3 users (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 David Konecny 2009-12-16 14:18:57 UTC
[I'm filling this as DEFECT only so that it stays on our radar and gets implemented for 6.9]

Following technologies will be made optional in next release of EE (>6):

   EJB 2.x entity beans
   JAX-RPC
   JAXR
   JSR-88 (Deployment API) 

Consequently, a number of API packages are proposed optional:

   javax.enterprise.deploy.model
   javax.enterprise.deploy.model.exceptions
   javax.enterprise.deploy.shared
   javax.enterprise.deploy.shared.factories
   javax.enterprise.deploy.spi
   javax.enterprise.deploy.spi.exceptions
   javax.enterprise.deploy.spi.factories
   javax.enterprise.deploy.status
   javax.xml.registry
   javax.xml.registry.infomodel
   javax.xml.rpc
   javax.xml.rpc.encoding
   javax.xml.rpc.handler
   javax.xml.rpc.handler.soap
   javax.xml.rpc.holders
   javax.xml.rpc.server
   javax.xml.rpc.soap

"Note that these APIs are not deprecated as such. In particular, they are not tagged in the javadocs nor annotate specially. From the point of view of the API itself, everything is fine; it's in the context of the platform that we want to discourage developers from using these APIs in their new applications."

I would suggest to start with very simple solution. We can create an hint, which will appear in the editor where the developer is using class from the optional packages, notifying him about the problem. This is the simplest solution which don't require any API changes. Once there is more and more optional packages we can provide better UI support (marking classes in code completion etc.). Such a solution will require API changes.
Comment 1 David Konecny 2011-01-23 22:38:05 UTC
Fixed - references to classes from optional packages will have WARNING hint with text saying "Be aware that this API will be optional in EE 7 platform". Hint is enabled by default and users can turn it off if they desire so.

4af942e226f6