geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anshuk Chinmoy Pal Chaudhuri" <Anshuk_PalChaudh...@infosys.com>
Subject RE: Stuck in deploying MDB
Date Tue, 23 May 2006 03:13:04 GMT
 
Hi Aaron,

I do not want a J2EE Application Client in the J2EE Client Container to
look up the JMS Resources.
Rather,I would change the way I am trying to connect to the Active MQ
server.
Can you please let me know how can I do that?

Warm Regards,
Anshuk Pal Chaudhuri

-----Original Message-----
From: ammulder@gmail.com [mailto:ammulder@gmail.com] On Behalf Of Aaron
Mulder
Sent: Monday, May 22, 2006 8:17 PM
To: user@geronimo.apache.org
Subject: Re: Stuck in deploying MDB

A normal "J2SE" application client can't look up JMS resources in the
server like this.  You have two choices:

1) Make it a proper J2EE application client that runs in the J2EE client
container

2) Change the way you're trying to connect to the ActiveMQ server

Any thoughts on which way you want to go?

Thanks,
    Aaron

On 5/22/06, Anshuk Chinmoy Pal Chaudhuri
<Anshuk_PalChaudhuri@infosys.com> wrote:
>
>
> Thanks Shai.
> It worked and the MDB got deployed.
> But I am having some kind issue in context with the JMS Client.
> Here is the client code:
>
>
>
>
>
> public class JMSClient {
>
> public final static String JNDI_FACTORY = 
> "org.activemq.jndi.ActiveMQInitialContextFactory";
>
> public final static String URL = "tcp://localhost:61616";
>
>
>
> private static Context jndiContext = null;
>
> private static QueueConnectionFactory factory = null;
>
> private static Queue receiveQueue = null;
>
> private static final String QueueName =
>
> "QueueRequest";
>
> /*private static final String FactoryName =
>
> "DefaultActiveMQConnectionFactory";*/
>
>
>
> public static Context getInitialContext() throws NamingException {
>
>
>
> if(jndiContext == null){
>
> Hashtable properties = new Hashtable();
>
> properties.put(Context.INITIAL_CONTEXT_FACTORY,JNDI_FACTORY);
>
> properties.put(Context.PROVIDER_URL, URL);
>
> properties.put(Context.SECURITY_PRINCIPAL,"geronimo");
>
> properties.put(Context.SECURITY_CREDENTIALS,"geronimo");
>
> jndiContext = new InitialContext(properties);
>
> }
>
> return jndiContext;
>
> }
>
> /**
>
> * @param args
>
> */
>
> public static void main(String[] args) {
>
> // TODO Auto-generated method stub
>
> QueueConnection queueConn = null;
>
> QueueSession queueSess = null;
>
> TextMessage myMessage = null;
>
> QueueSender queueSender = null;
>
>
>
> try {
>
> jndiContext = getInitialContext();
>
> ActiveMQConnectionFactory ac = new ActiveMQConnectionFactory(URL);
>
> receiveQueue = (Queue)
>
> jndiContext.lookup(QueueName);
>
> queueConn = ac.createQueueConnection();
>
> queueSess = queueConn.createQueueSession(false,
>
> Session.AUTO_ACKNOWLEDGE);
>
> queueSender = queueSess.createSender(receiveQueue);
>
> myMessage = queueSess.createTextMessage();
>
> myMessage.setText("Sample Message");
>
> queueSender.send(myMessage);
>
> queueSender.close();
>
> queueSess.close();
>
> queueConn.close();
>
> }
>
> catch (Exception e) {
>
> e.printStackTrace(System.out);
>
> }
>
> }
>
> }
>
> Its throwing that couldn't find the Queue with the name 
> "QueueRequest". What I want to know is that all the configuration for 
> the client is correct or not?
>
> Warm Regards,
> Anshuk Pal Chaudhuri
>
>
>  ________________________________
>  From: Shai Wolf [mailto:shai.wolf@coridan.com]
> Sent: Monday, May 22, 2006 3:09 PM
>
> To: user@geronimo.apache.org
> Subject: RE: Stuck in deploying MDB
>
>
>
>
>
> Hi Anshuk,
>
>
>
> I am new with Geronimo and I had the same problem.
>
> It is true that there is no module called
org/apache/Geronimo/SystemJMS.
>
> It is probably an old JMS module name.
>
> Try to replace this name with geronimo/activemq/1.0/car which is the 
> name of the ActiveMQ JMS module.
>
> It should work.
>
>
>
> Good luck and regards,
>
> Shai Wolf
>
> Coridan Inc.
>
>
>
>  ________________________________
>
>
> From: Anshuk Chinmoy Pal Chaudhuri 
> [mailto:Anshuk_PalChaudhuri@infosys.com]
> Sent: Monday, May 22, 2006 11:24 AM
> To: user@geronimo.apache.org
> Subject: RE: Stuck in deploying MDB
>
>
>
> When I deploy org/apache/geronimo/SystemJMS project. Geronimo report 
> error
> that...:
>
>
>
> D:\geronimo-1.0\bin>java -jar deployer.jar start 
> org/apache/geronimo/SystemJMS
> Username: system
> Password:
>
>
>
>
>     Error: org/apache/geronimo/SystemJMS does not appear to be a the
>     name of a module available on the selected server. Perhaps it has
>     already been stopped or undeployed?  If you're trying to specify a
>     TargetModuleID, use the syntax TargetName|ModuleName instead. If
>     you're not sure what's running, try the list-modules command.
>
>
> Any pointers what kind of error is that?
>
>
> How do I register the project with config id
org/apache/geronimo/SystemJMS?
>
>
> If I dont then I wont be able to deploy MDB on the server.
>
> Warm Regards,
> Anshuk Pal Chaudhuri
> SETLabs - Web Services CoE
>
>
>  ________________________________
>
>
> From: Anshuk Chinmoy Pal Chaudhuri 
> [mailto:Anshuk_PalChaudhuri@infosys.com]
> Sent: Monday, May 22, 2006 11:06 AM
> To: user@geronimo.apache.org
> Subject: Stuck in deploying MDB
>
>
>
> <<ejb-jar.xml>>
> <<JMS_CLIENT_MDB_LISTENER_DEPLOYMENT_PLAN.xml>>
> <<openejb-jar.xml>>
> Hi,
>
> I am having some issues in deploying MDB's on Geronimo 1.0 reagrding 
> the parent id.
> I do not have ear application files as such.Just a simple MDB 
> listening to a queue.
>
> I have created the queues (which is mentioned in the MDB config files)

> using the resource adapater file from the activemq-ra-3.2.1 file.
>
> The resource adapter file contains the parent id:
> geronimo/activemq-broker/1.0/car
>
> The parent id of the MDB deployment file has to be 
> org/apache/geronimo/SystemJMS otherwise it will throw an error of
> java.lang.ClassNotFoundException:
> org.activemq.ra.ActiveMQActivationSpec,true. But while deploying the 
> MDB using the parent id: org/apache/geronimo/SystemJMS,there
> is an error saying that Unable to load first parent of configuration 
> TESTING_JMS_MDB No configuration with id: 
> org/apache/geronimo/SystemJMS
>
> I have attached the configuration files:
>
> JMS_CLIENT_MDB_LISTENER_DEPLOYMENT_PLAN.xml (resource adapter file to 
> create queues) ejb-jar.xml openejb-jar.xml
>
> The default activemq-broker application is running.
> Is it to do with that or something?
> Can somebody let me know asap what else configuration do I need to 
> make to make that working?
>
>
>
> Warm Regards,
> Anshuk Pal Chaudhuri
>
>
> **************** CAUTION - Disclaimer ***************** This e-mail 
> contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for 
> the use of the addressee(s). If you are not the intended recipient, 
> please notify the sender by e-mail and delete the original message. 
> Further, you are not to copy, disclose, or distribute this e-mail or 
> its contents to any other person and any such actions are unlawful. 
> This e-mail may contain viruses. Infosys has taken every reasonable 
> precaution to minimize this risk, but is not liable for any damage you

> may sustain as a result of any virus in this e-mail. You should carry 
> out your own virus checks before opening the e-mail or attachment. 
> Infosys reserves the right to monitor and review the content of all
messages sent to or from this e-mail address.
> Messages sent to or from this e-mail address may be stored on the 
> Infosys e-mail system.
> ***INFOSYS******** End of Disclaimer ********INFOSYS***
>
>
>

Mime
View raw message