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.
When switching servers, j2eeserver calls initConfiguration() to initialize a second DeploymentConfiguration on the OLD server. I don't think this is correct. To reproduce, pick a server, put a breakpoint or println in the init routine for that server's plugin (I used SJSAS, of course, and checked both Web Projects and EjbProjects). Then run, note the first (correct) initialization when the project is loaded or created. Then switch servers to another server (e.g SJSAS -> Tomcat or JBoss). There will be a second init call caused by the ensureConfigurationReady() calls in J2eeModuleProvider.fireServerChange(), which are sent to the old server plugin when it appears they had been intended for the new one. If somehow this behavior is correct, we may need to upgrade the API, and we do need to document the lifecyle of a DeploymentConfiguration better. In this case, there are two DeploymentConfiguration's in existence simultaneously for a period of time, which implies duplicate DConfigBeans and all the bad news that goes with that, as well as some other shortcomings I can enumerate if it becomes necessary.
TM -> 5.0
The problem was that the ear project never fired server change event. The problem with ejbjar and web projects was that the server change event was fired before server instance ID had been updated to the new value. Peter, please feel free to reopen this issue, if your problems persist. Thanks F. Checking in src/org/netbeans/modules/web/project/ProjectWebModule.java; /cvs/web/project/src/org/netbeans/modules/web/project/ProjectWebModule.java,v <-- ProjectWebModule.java new revision: 1.44; previous revision: 1.43 done Checking in src/org/netbeans/modules/j2ee/earproject/ProjectEar.java; /cvs/j2ee/earproject/src/org/netbeans/modules/j2ee/earproject/ProjectEar.java,v <-- ProjectEar.java new revision: 1.13; previous revision: 1.12 done Checking in src/org/netbeans/modules/j2ee/ejbjarproject/EjbJarProvider.java; /cvs/j2ee/ejbjarproject/src/org/netbeans/modules/j2ee/ejbjarproject/EjbJarProvider.java,v <-- EjbJarProvider.java new revision: 1.29; previous revision: 1.28 done