[jboss-dev-forums] [Design of JMX on JBoss (JBoss/JMX)] - Is there a SAR Context? How can I get it?

dervillo do-not-reply at jboss.com
Wed Apr 1 10:10:11 EDT 2009


Hi JBoss friens!

This is my first message in the forum, so sorry if I make some mistake...

I??ve created a framework that contains a DatabaseFactory class.

At this moment I already have two applications extending this framework and each one needs to access a specific DB.

I??m using a MBean to start this applications and I would like to get a Context for each sar, and put the JNDI name into this Context, so the DatabaseFactory could get this JNDI Name when asked for create a Connection.

I wouldn??t like to propagate the JNDI Name since the MBean to the DatabaseFactory, since there are multiple classes between the way, and I think it is not so elegant...

So here I put my main question: Is there a SAR Context? How can I get it?

I??m using JBOSS 3.2.6 and Java 1.4.18.

Thank you so much!!! 

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

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



More information about the jboss-dev-forums mailing list