3 Replies Latest reply on Feb 14, 2012 9:32 PM by Udo

    WebLogic listener - change apex-config.xml location ?

    789829
      HI guys,

      I've got the WebLogic APEX listener running with APEX 4... but have an issue...

      When I run the configureListener servlet, it appears to default to using /tmp/ as the location for apex-config.xml... which is fine until you reboot your server and /tmp gets cleaned-up.

      I've found a post that suggests that you can configure the location for the config file in web.xml, but I can't work out where web.xml IS when running WebLogic! If I was running Tomcat or Glassfish I'd know how to find it, but can't work it out for WebLogic.

      Any pointers please?

      cheers. Jerry
        • 1. Re: WebLogic listener - change apex-config.xml location ?
          Udo
          Hi Jerry,

          I don't know much about the WLS, but when we had a try on migrating from "old" OAS (OC4J), I found that document helpful:
          http://download.oracle.com/docs/cd/E13222_01/wls/docs90/deployment/understanding.html
          As you'll see there, the web.xml doesn't persist the deployment process. I don't know if editing the result files is a good idea, because the changes may be overwritten as soon as you touch anything in the deployment configuration afterwards.
          So I'd suggest two other options:

          1. Unpack the apex.war ( tar -xf apex.war ), edit the web.xml in the unpacked structure, repack the war ( tar -cf apex.war . ) and deploy it.
          2. Chose +$HOME/<Mount Point>/apex-config.xml+ which is searched before the tmpdir instead of using config.dir. But as I think of it, I'm not sure if this will persist in WLS if you redeploy.

          I prefer the first option. I know it's sounds a bit complicated to repack the war, but at the end you get an archive you could easily deploy on any other system using your configuration changes - no need to change anything on the deployed application.

          -Udo
          • 2. Re: WebLogic listener - change apex-config.xml location ?
            snmdla
            I don't quite understand why they decided to let apex-config.xml live in /tmp in the first place. Who on earth directs configuration files to /tmp directories?

            Opinions welcome.

            Regards, Tom
            • 3. Re: WebLogic listener - change apex-config.xml location ?
              Udo
              Hello Tom,
              I don't quite understand why they decided to let apex-config.xml live in /tmp in the first place. Who on earth directs configuration files to /tmp directories?
              I don't quite understand why you responded to this thread - your answer is most likely not very helpful for the OP.
              Anyway, this question, though in a more polite way, has been asked a few times before... I'll try to answer it for you again.

              First: If you read the Installation and Developer Guide for APEX Listener, especially the section "Configuration File", you'll understand the concept.
              But to keep it short for you: APEX Listener is supposed to run on multiple platforms, which is one of the main reasons for the rather generic approach to locate the configuration, and especially to enable a user to create the initial configuration.
              The actual default location depends on your JEE Container and its configuration, as it will be in +${java.io.tmpdir}+ if nobody setup anything. I don't know any other location you can be sure to have access to in any container on any OS. Do you?
              Personally, I appreciate the fact that APEX Listener will run out of the box without much configuration in the first place, though it seems to keep people from reading the manual at all, because everything seems to run out of the box like magic. And it does, until your tmpdir gets cleaned up. Complaining about that seems to me a bit like booting a Live-CD and arguing why all your settings are gone once you reboot.

              -Udo