--local-copy=true

2009-08-24 Thread Rodney B. Cabahug
Hello,
How can I specify --local-copy=true startup argument to the openejb server
in geronimo?
Thanks

Regards,
Rodney Cabahug


openejb.localcopy=false

2009-08-24 Thread Rodney B. Cabahug
Hi! How do I specify openejb.localcopy=false argument for openejb during
startup in geronimo? Thanks.
Regards,
Rodney Cabahug


Message Driven Bean is not receiving messages

2009-08-24 Thread Stephan Mehlhase
Hi everyone,

My setup is the following: I'm using Geronimo 2.1.4 on linux under
Java 1.6 developing with Eclipse 3.5 EE (I'm using the nightly built
2.1.5 GEP plugin)

I'm trying to set up a small message driven bean which receives
messages that I've send from a JAX-WS Webservice. So I went into the
adminstration console and created a JMS resource with one connection
factory and one destination (called Test, TestFactory and TestQueue
respectively). After doing so I wrote the webservice and it looks like
this:

@WebService
public class TestServer {
private static final Logger log = Logger.getLogger(TestServer.class);
@Resource(name = "TestFactory")
private ConnectionFactory factory;
@Resource(name = "TestQueue")
private Destination destination;

@WebMethod
public void test() {
try {
Connection con = factory.createConnection();
Session s = con.createSession(false, 
Session.AUTO_ACKNOWLEDGE);
MessageProducer p = s.createProducer(destination);
con.start();
p.send(s.createTextMessage("Test"));
con.close();
log.info("Sent message");
} catch (JMSException e) {
log.warn("Exception", e);
}
}
}
(I'm not sure whether the connection.start() call is necessary but I
added it "just in case" - it does not work without neither)
Than I created the EJB like this:

@MessageDriven(activationConfig = {
@ActivationConfigProperty(propertyName = "destinationType",
propertyValue = "javax.jms.Queue"),
@ActivationConfigProperty(propertyName = "destination",
propertyValue = "TestQueue") }, mappedName = "TestQueue")
public class MDB implements MessageListener {
private static Logger log = Logger.getLogger(MDB.class);

public void onMessage(Message message) {
log.info("WE GOT A MESSAGE!");
}
}

(I've played around with the items of @MessageDriven annotation
(removing activation config, removing the mapped name) - nothing did
change anything).
The openejb-jar.xml is:




default
TestEJB
1.0
car



console.jms
Test
1.0
rar





MDB

Test





(I left out some namespace declarations)


If I invoke the webservice I see the "Sent message" log entry but the
EJB seems not to receive it (in fact it even does not get
instantiated).
So I checked the logs and have not found any error message and
therefore enabled the logs for ActiveMQ to see whether the message is
actually received. I found the following:

Upon deployment:
2009-08-24 14:49:35,174 INFO  [startup] Jndi(name=TestEJB/MDB) -->
Ejb(deployment-id=TestEJB/MDB)
2009-08-24 14:49:35,208 DEBUG [ActiveMQEndpointWorker] Starting
2009-08-24 14:49:35,219 DEBUG [ActiveMQEndpointWorker] Started
2009-08-24 14:49:35,219 INFO  [startup] Created
Ejb(deployment-id=TestEJB/MDB, ejb-name=MDB,
container=console.jms/Test/1.0/rar.Test-javax.jms.MessageListener)
2009-08-24 14:49:35,219 INFO  [startup] Deployed
Application(path=/tmp/geronimo-deployer282244042823023765.tmpdir/TestEJB.zip)
[...]
2009-08-24 14:49:35,328 DEBUG [AbstractRegion] Adding destination:
queue://TestEJB/MDB
2009-08-24 14:49:35,356 DEBUG [JournalPersistenceAdapter] Waking for
checkpoint to complete.
2009-08-24 14:49:35,387 DEBUG [JournalPersistenceAdapter] Checkpoint started.
2009-08-24 14:49:35,390 DEBUG [JournalPersistenceAdapter] Checkpoint done.
2009-08-24 14:49:35,414 DEBUG [AbstractRegion] Adding destination:
topic://ActiveMQ.Advisory.Queue
2009-08-24 14:49:35,423 DEBUG [AbstractRegion] Adding destination:
topic://ActiveMQ.Advisory.Consumer.Queue.TestEJB/MDB


Upon Invocation of the Webservice:
2009-08-24 14:50:01,022 DEBUG [ActiveMQSession] Sending message:
ActiveMQTextMessage {commandId = 0, responseRequired = false,
messageId = ID:yoda-40121-1251118162624-3:4:1:1:1, originalDestination
= null, originalTransactionId = null, producerId =
ID:yoda-40121-1251118162624-3:4:1:1, destination = topic://testqueue,
transactionId = null, expiration = 0, timestamp = 1251118201019,
arrival = 0, correlationId = null, replyTo = null, persistent = true,
type = null, priority = 4, groupID = null, groupSequence = 0,
targetConsumerId = null, compressed = false, userID = null, content =
null, marshalledProperties = null, dataStructure = null,
redeliveryCounter = 0, size = 0, properties =