[Design of POJO Server] - JMS ConnectionFactory not bound issue
by anil.saldhana@jboss.com
As of yesterday, I am seeing the following error affecting some of the MDB tests.
| ConnectionFactory not bound
|
| javax.naming.NameNotFoundException: ConnectionFactory not bound
| at org.jnp.server.NamingServer.getBinding(NamingServer.java:771)
| at org.jnp.server.NamingServer.getBinding(NamingServer.java:779)
| at org.jnp.server.NamingServer.getObject(NamingServer.java:785)
| at org.jnp.server.NamingServer.lookup(NamingServer.java:443)
| at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
| at sun.rmi.transport.Transport$1.run(Transport.java:153)
| at java.security.AccessController.doPrivileged(Native Method)
| at sun.rmi.transport.Transport.serviceCall(Transport.java:149)
| at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:466)
| at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:707)
| at java.lang.Thread.run(Thread.java:595)
| at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)
| at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)
| at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
| at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:713)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:673)
| at javax.naming.InitialContext.lookup(InitialContext.java:351)
| at org.jboss.test.security.test.EJBSpecUnitTestCase.testMDBRunAs(EJBSpecUnitTestCase.java:601)
| at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
| at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
| at junit.extensions.TestSetup.run(TestSetup.java:25)
|
Was this the messaging upgrade or something in "connector"?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4192557#4192557
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4192557
15 years, 7 months
[Design of POJO Server] - Re: ProfileService Guidance
by sguilhen@redhat.com
I am developing a test case for managed security domains, and as part of this test I deploy a sample testdomains-jboss-beans.xml that contains some JaasSecurityDomain bean declarations:
| <?xml version="1.0" encoding="UTF-8"?>
|
| <!-- sample security domain beans used in the profile service tests -->
| <deployment xmlns="urn:jboss:bean-deployer:2.0">
|
| <annotation>@org.jboss.managed.api.annotation.ManagementDeployment(description="JBoss SecurityDomain Beans")</annotation>
|
| <bean name="TestDomain1" class="org.jboss.security.plugins.JaasSecurityDomain">
| <constructor>
| <parameter>TestDomain1</parameter>
| </constructor>
| <property name="keyStorePass">somepass1</property>
| <property name="salt">abcdefgh</property>
| <property name="iterationCount">13</property>
| </bean>
|
| <bean name="TestDomain2" class="org.jboss.security.plugins.JaasSecurityDomain">
| <constructor>
| <parameter>TestDomain2</parameter>
| </constructor>
| <property name="keyStorePass">somepass2</property>
| <property name="salt">abcdefgh</property>
| <property name="iterationCount">17</property>
| </bean>
|
| </deployment>
|
However, I noticed that the JaasSecurityDomain beans are only processed by the Management view if the testdomains-jboss-beans.xml file is deployed before starting the profileservice partition. If I deploy this file after the server has been started, it is not processed by the management layer and thus the JaasSecurityDomain managed objects cannot be found when calling ManagementView.getComponent().
In the test method, I am doing something along the lines of
| String resource = getResource("profileservice/security/testdomains-jboss-beans.xml");
| super.deploy(resource);
|
| ManagementView managementView = getManagementView();
| managementView.reloadProfile();
| ComponentType type = new ComponentType("MCBean", "Security");
| ManagedComponent mc = managementView.getComponent("TestDomain1", type);
| assertNotNull(mc);
|
| super.undeploy(resource);
|
The code above returns a null ManagedComponent, unless I deploy the testdomains-jboss-beans.xml before starting the AS. So, my question is what do I need to do to properly register the managed components at runtime? I'm guessing that only deploying the -jboss-beans.xml is not enough and that I need somehow to notify the management components to process the newly created beans.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4192543#4192543
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4192543
15 years, 7 months