OK, there were several problems here, thanks for pointing out the
situation.

1. I installed some bugs in ServiceController when I made a state machine
for mbean state.  It wasn't possible to get into NOTINITIALIZABLE or
NOTSTARTABLE states, so mbeans could get stuck in RUNNING even when they
weren't (fixed)

2. ServiceMBeanSupport was duplicating the stack trace from
ServiceController.  (fixed)

3. The test suite setup in JBossTestCase.getDeploySetup wasn't undeploying
a package that failed deployment. (fixed)

4. The ejb deployment system appears to parse the entire jbosscmp-jdbc.xml
file for each ejb, and match up the listed fields with those declared in
ejb-jar.xml for the entire file each time.  Therefore, if there is an error
in one ejb config, all ejb's can't be processed.  I don't think this is a
very desirable situation.  I would prefer to solve it by combining all the
dds into one file containing all the info, in the form of mbean
configurations for the containers, then deploying this generated mbean
configuration file, however I'm not planning on doing this tonight.  A
simpler short term solution might be to process the xml file once, before
trying to deploy any ejbs, and stop if it fails. (not fixed)

What happens now when you try to run a bogus test like this is that you get
one stack trace for each ejb in the ejb-jar package (see 4 for why), the
deployment fails with an IncompleteDeploymentException, and the test case
does not try to run the tests.  The partially deployed ejb-jar package is
undeployed by the test framework.

david jencks


On 2002.08.30 16:32:56 -0400 Dain Sundstrom wrote:
> My startup code throws DeploymentExceptions if an error is detected in 
> the configuration, and this used to cause deployment to stop.  I doesn't 
> anymore.
> 
> In org.jboss.system.ServiceController.start(ObjectName) we have the 
> following code on line 366 (HEAD):
> 
> // Call start on the service Proxy
> try
> {
>     ctx.proxy.start();
> }
> catch (Throwable e)
> {
>     ctx.checkTransition(ServiceContext.NOTSTARTABLE);
>     ctx.problem = e;
>     log.warn("Problem starting service " + serviceName, e);
>     return;
> }
> 
> This simply writes an unnecessary exception trace and allows the 
> deployment to continue.
> 
> Is there a reason for this code?  If not I will be more then happy 
> remove the try/ catch and allow the code to exception out.
> 
> 
> BTW:  If you want to reproduce this error modify the 
> src/resources/cmp2/commerce/META-INF/jbosscmp-jdbc.xml and add some junk 
> to one of the cmp-field names (like change userName to userNameXXXXX). 
> Then run the following command:
> 
> ./build.sh -Dtest=org.jboss.test.cmp2.commerce.CommerceTest one-test
> 
> Watch the 30 pages of exceptions flow by and the app still deploys.
> 
> -- 
> xxxxxxxxxxxxxxxxxxxxxxxx
> Dain Sundstrom
> Chief Architect JBossCMP
> JBoss Group, LLC
> xxxxxxxxxxxxxxxxxxxxxxxx
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by: OSDN - Tired of that same old
> cell phone?  Get a new here for FREE!
> https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
> _______________________________________________
> Jboss-development mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-development
> 
> 


-------------------------------------------------------
This sf.net email is sponsored by: OSDN - Tired of that same old
cell phone?  Get a new here for FREE!
https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to