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.
Please review these suggested changes of the j2eeserver API. Web and other types of projects need be notified when the server instance which they use is removed so that appropriate steps (like reporting "missing server problem") could be taken. To make this possible a property change listener should be added to the Deployment class. Methods for listing registered server instances that meet some requirements (supported module types, J2EE specification versions and tools) should be also added to the same class. This will be used by wizards and customizers that need to list server instances based on certain criterias. The only class affected by this change is org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment.
Created attachment 19837 [details] J2EEServerAPI javadoc
Created attachment 19838 [details] j2eeserver diff
This is a trivial and compatible change -> API_REVIEW_FAST.
DeploymentAccessor reminds me my trick from http://openide.netbeans.org/tutorial/api-design.html#design.less.friend I am flattered. And yes, adding something to final class looks compatible enough.
Changes made to follow Nam's suggestions. Thank you Nam. InstanceListener will be used instead of the PropertyChangeListener and will be registered not in the Deployment class but in the J2eeModuleProvider. Affected API classes/interfaces: org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider org.netbeans.modules.j2ee.deployment.devmodules.spi.InstanceListener - added
Created attachment 19924 [details] J2EEServerAPI.zip updated
Created attachment 19925 [details] j2eeserver diff - updated
I agree with the proposed changes. Go ahead and integrate them.
Created attachment 20003 [details] Commit log
Fixed.