[jboss-user] [Installation, Configuration & DEPLOYMENT] - Deployment using JSR88

prashanthvvbabu do-not-reply at jboss.com
Thu Oct 18 15:26:56 EDT 2007


Hi,

I have been working on JSR88 API for Deploy/Undeploy/Stop/Start of an EJB on JBossASv4.0.2. I was able to deploy/undeploy an EJB, but I was not able to start/stop an app. Later I found out that start/stop were not implemented in that version.

So, I moved to 4.0.5.GA and later to 4.2.1.GA. But, there were some changes in the URI and others. Now, am not even able to connect to the JBossAS. Am I doing something basically wrong..


  | public class Main { 
  |     public static void main(String[] args) { 
  |         try { 
  |             javax.enterprise.deploy.spi.factories.DeploymentFactory df = new org.jboss.deployment.spi.factories.DeploymentFactoryImpl(); 
  |             javax.enterprise.deploy.spi.DeploymentManager dm; 
  |             dm = df.getDeploymentManager("http://org.jboss.deployment/jsr88", null, null); 
  |             javax.enterprise.deploy.spi.Target[] targets = dm.getTargets(); 
  |             javax.enterprise.deploy.spi.TargetModuleID[] modules; 
  |             modules = dm.getAvailableModules(javax.enterprise.deploy.shared.ModuleType.EJB, targets); 
  | 
  |             System.out.println(targets.length + " " + targets[0]); 
  |             System.out.println(modules); 
  |              
  |         } catch (javax.enterprise.deploy.spi.exceptions.DeploymentManagerCreationException ex) { 
  |           ex.printStackTrace();
  |         } catch (javax.enterprise.deploy.spi.exceptions.TargetException ex) { 
  |           ex.printStackTrace();
  |         } 
  |     } 
  | } 
  | 

The error I get is :
anonymous wrote : 
  | Caused by: javax.naming.CommunicationException: Could not obtain connection to any of these urls: localhost:1099 and discovery failed with error: javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out] 
  |  [Root exception is javax.naming.CommunicationException: Failed to connect to server localhost:1099
  |   [Root exception is javax.naming.ServiceUnavailableException: Failed to connect to server localhost:1099 [Root exception is java.net.ConnectException: Connection refused: connect
  |   ]
  |  ]
  | ]
  | 

I tried with a different URI ("jnp://localhost:1099") also. But, it does not fetch me any modules. Iam unable to understand, what Iam doing wrong.
Please let me know. Am badly stuck. Any pointers to any documentation/examples will also be helpful.

TIA...

Thanks and Regards,

Prashanth Babu.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096708#4096708

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096708



More information about the jboss-user mailing list