12 Replies Latest reply: Apr 23, 2012 7:04 AM by Udo RSS

    Apex Listener reliabilty problem on Glassfish

    Bob T.
      Environment:
      Windows server 2008 r2 64 bit
      Glassfish 3.1.2 installed and working fine.
      Apex 4.1.1
      Listener 1.1.3.243.11.40

      1. Created roles
      2. Deployed war file
      3. Configured listener thorugh web url
      4. can access listenerAdmin url to configure allowed security parameters such as www_flows*, etc.
      At one point after saving admin screen I was taken to apex login and was able to login fine, etc.

      Rebooted server before I left and upon coming back, can not bring he apex login page up. I get a blank screen.

      Images are copied to domain1/docroot/i directory

      I am not getting page refused or such message just a blank page.

      Bob
        • 1. Re: Apex Listener reliabilty problem on Glassfish
          Bob T.
          Okay, I suspect I found a bug with the listener.

          Normally whe listener is deployed with context of: apex
          The /i/ directory for images is located off of docroot for domain1.

          However, I have another EE application that I installed that starts with context of root. Say this application is eclerk

          If I move i directory from docroot to say: D:\glassfish3\glassfish\domains\domain1\applications\eclerk\eclerk-storedir\i

          All works fine and I can now login with no problems.
          • 2. Re: Apex Listener reliabilty problem on Glassfish
            Udo
            Hi Bob,
            Okay, I suspect I found a bug with the listener.
            I think you've found a "bug" in your GlassFish deployments or in the way you think they work. ;)
            The /i/ directory for images is located off of docroot for domain1.
            However, I have another EE application that I installed that starts with context of root. Say this application is eclerk.
            You should have mentioned this in your first post as well.
            If you "kicked" the root context by deploying some regular webapp to it, you can't expect the "docroot" for static contents to serve your images any more. The "docroot" is managed by the application you've deployed in there, so it's not very surprising that moving your images into the context of that application makes them available in a registered context again.
            You could also create a war file (e.g. named i.war ) for your images and deploy that to the context +/i/+ or you could add so called alternated docroot properties as noted in the [url http://docs.oracle.com/cd/E18930_01/html/821-2418/beaft.html#geqpl]Application Development Guide for GF 3.1 (it works for older GF release the same way).

            -Udo
            • 3. Re: Apex Listener reliabilty problem on Glassfish
              Bob T.
              thanks for the reponse. For the first post, I knew I had a problem but did not know what it was. After the first post and some testing, I discovered what I wrote in the second post.

              Thanks for the response.
              Bob
              • 4. Re: Apex Listener reliabilty problem on Glassfish
                Udo
                For the first post, I knew I had a problem but did not know what it was. After the first post and some testing, I discovered what I wrote in the second post.
                No problem. All I wanted to state was that this kind of "non-standard deployment" is hard to expect from "outsiders"...

                Anyway, it would be nice to know if you've got your system working with one of the suggested solutions.

                If your question is answered, please mark this thread and any helpful or correct answer accordingly, so other users searching for a similar issue can spot relevant posts easily.

                Thanks,

                Udo
                • 5. Re: Apex Listener reliabilty problem on Glassfish
                  Bob T.
                  The solution worked great.

                  The details are:

                  In admin console, go to virtual server property under Server config tab. Add property to virtual server.

                  In name enter: alternatedocroot_1
                  Value: from=/i/* dir=/docroot/i

                  I then copied i directory over to docroot. All works fine.


                  Update.......
                  Not working that great! When I am on the server I can access apex console fine with no problems.

                  If I am on a client workstation and use same url, pages are not displayed......stilll working on the problem......

                  Edited by: Bob T. on Apr 18, 2012 9:15 PM
                  • 6. Re: Apex Listener reliabilty problem on Glassfish
                    Bob T.
                    Unforseen problem as noted in thread.
                    • 7. Re: Apex Listener reliabilty problem on Glassfish
                      Udo
                      Update.......
                      Not working that great! When I am on the server I can access apex console fine with no problems.

                      If I am on a client workstation and use same url, pages are not displayed......stilll working on the problem......
                      What exactly do you mean with "apex console"? Some APEX Listener page, e.g. +/listenerAdmin/+ or the actual APEX Workspace login?
                      Do you receive any error message on your client when calling that URL? Or do you see any error in APEX Listener's log (GlassFish log) when you call from external
                      There may be a few reasons for that problem. Most likely you have some kind of network issue, e.g.
                      - The client can't reach the server at all (wrong network/routing).
                      -- Can your client "ping" the server?
                      - A firewall is blocking the access to the port used by APEX Listener.
                      -- Check the firewall on your server and see if the TCP port used by your GlassFish (default 8080) is allowed to be connected from the client's network.
                      - You have a port conflict, i.e. port 8080 is in used by another service.
                      -- This could be the database internal XDB HTTP Server that would be used to serve APEX with the so called "Embedded PL/SQL Gateway" (EPG). This service defaults to port 8080 as GlassFish does. It might be that it's just listening on the public interface of your server, so localhost access can be served by APEX Listener. You could either reconfigure your GlassFish to use a different port or reconfigure or disable the XDB HTTP Server in your database. The latter would be done by calling sqlplus as sysdba and the following command
                      exec dbms_xdb.sethttpport(&new_port);
                      commit;
                      where new_port is a port different from 8080, e.g. 8081, or 0 to disable the service.

                      I hope this helps you resolve your issue. If not, please provide some more information for debugging, as requested above. (Logs, error messages)

                      -Udo
                      • 8. Re: Apex Listener reliabilty problem on Glassfish
                        Bob T.
                        I am referring to the apex login screen for admin as well as developer.

                        If I move the i folder back to original context and remove the virtual server property setting in glassfish all works fine from the client. If I insert the property setting and move the folder to alternate context as listed in property setting and restart glassfish the login screen for apex is blank.

                        Network settings are fine.
                        • 9. Re: Apex Listener reliabilty problem on Glassfish
                          Udo
                          Could it be the Virtual Server you've added the property to is serving just the localhost?
                          Please see the [url http://docs.oracle.com/cd/E18930_01/html/821-2416/ggncs.html]GF 3.1 Administration Guide details on how to setup Virtual Servers and how to determine the configuration of existing instances.

                          -Udo
                          • 10. Re: Apex Listener reliabilty problem on Glassfish
                            Bob T.
                            Well, after reading your response, I removed the property entries from the server config section and entered the property under the default config section.

                            Saved settings and moved i folder to docroot folder and rebooted server. Testing from client works fine!

                            Thanks,
                            Bob
                            • 11. Re: Apex Listener reliabilty problem on Glassfish
                              Bob T.
                              Spoke too soon again.

                              apex login page appears. After logging in many of the gifs, etc. do not appear. When checking the property settings on html page of missing picture, it show apex is looking to root context of i

                              If I create folder of i at alternate root context and copy missing pictures, gifs, they appear on the screen. This DOES seem to be a problem with apex listener.

                              Suspect nothing can be done of this........

                              Bob
                              • 12. Re: Apex Listener reliabilty problem on Glassfish
                                Udo
                                Hi Bob,

                                I'm sorry to hear you still got problems with your APEX Listener instance.
                                This DOES seem to be a problem with apex listener.
                                I don't think so. You've already mentioned the key aspect to this issue, but it seems you draw a wrong conclusion:
                                When checking the property settings on html page of missing picture, it show apex is looking to root context of i
                                What exactly do you mean? That you get the images prefix you've configured?
                                If I create folder of i at alternate root context and copy missing pictures, gifs, they appear on the screen.
                                So it seems your configuration for the root context, including your "root"-application, is not setup properly. Perhaps you have some conflicting patterns in there, perhaps some other aspect of your scenario is responsible for that.
                                I can assure you that APEX Listener neither checks nor adapts anything concerning your images configuration. This is only done within APEX itself with no regard on what is happening on the web server. You can even run it without having any APEX images on the same server instance, e.g. with putting something like Apache HTTPD in front to act as proxy for the APEX Listener (serving the context /apex/) and as "normal" web server for the APEX images (context /i/).
                                The issue is somewhere in your GlassFish configuration. But actually, I recommend this thread to stay closed, as this is no GlassFish forum and it seems you found a workaround you can accept...

                                -Udo