2 Replies Latest reply on Dec 5, 2006 3:11 AM by alexgout

    using TargetModuleID

    alexgout

      Hi,

      Im posting this on this forum, because it's the best I could find. I want to get some Runtime information about the application server instance (it's name) my ear is deployed in. I concluded form the J2EE space that the TargetModuleID and Target interface are what I need.

      But I can't find how Im supposed to use them. I saw one example but I didnt get that one ;),
      Anyone know where I can get the information from?

      Does anyone know?

      Regards,
      Alex

        • 1. Re: using TargetModuleID
          peterj

          Did you want to know if you are running in the "default" or "all" or whatever server? If so, you can look up the name via a system property:

          String server = System.getProperty("jboss.server.name");

          • 2. Re: using TargetModuleID
            alexgout

            Hi, thanks for your suggestion. I looked at that solution, but my problem is, it is jboss specific. I prefer to not use appserver specific references in my code.

            Any other ideas?

            Regards,
            Alex