Martin Husted Hartvig [
http://community.jboss.org/people/Hagar] created the discussion
"Re: Installing into JBoss 4.2.3 GA"
To view the discussion, visit:
http://community.jboss.org/message/582804#582804
--------------------------------------------------------------
Hi Federico,
This is the changes I made:
@Override
public void createDestination(Class<? extends Destination> type, String
jndiSuffix) throws Exception
{
String methodName;
String destinationContext;
if (type == Topic.class)
{
destinationContext = "topic";
methodName = "deployTopic";
}
else if (type == Queue.class)
{
destinationContext = "queue";
methodName = "deployQueue";
}
else
{
// type was not a Topic or Queue, bad user
throw new IllegalArgumentException
("Expected javax.jms.Queue or javax.jms.Topic: " + type);
}
String jndiName = (new
StringBuilder()).append(destinationContext).append("/").append(jndiSuffix).toString();
ObjectName destinationManagerName = new
ObjectName("jboss.messaging:service=ServerPeer");
KernelAbstraction kernel = KernelAbstractionFactory.getInstance();
// invoke the server to create the destination
Object result = kernel.invoke(destinationManagerName,
methodName,
new Object[]{jndiSuffix, jndiName},
new String[]{"java.lang.String", "java.lang.String"});
}
Rebuild the project and drop the jar into the depoly/ejb3.deployer folder. Hope this helps
you...
Regards,
Martin
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/582804#582804]
Start a new discussion in EJB3 at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]