I have managed to make the Apex Listener 2.0 work in both Standalone Mode as well as deploying in Glassfish. I have been trying to get the multiple database connection feature working but I'm seeing some odd results:
When I started the process, my configdir was set to /u01/app/oracle/product/apex/apex. The last directory is added during the configuration process.
I then added a new database connection using : java -jar apex.war setup --database <dbname>. This seemed to work.
When I tried setting up URL mapping using any of the three methods mentioned in the help, I see the files I expected <dbname.xml>, but they show up in a new directory. The configuration process adds a /apex to the configdir each time I run the map-url configuration. So after adding one database / map-url configuration, my configdir now looks like this:
/u01/app/oracle/product/apex/apex/apex. The last /apex directory contains a default.xml and a url-mapping.xml, but navigating to the mapped url results in a 404 error.
Today I have installed APEX listener 18.104.22.1688.17.04 as standalone listener.
APEX is running under http://localhost:8082/apex
Then I configured an URL mapping. The url-mapping.xml looks like:
<?xml version="1.0" encoding="UTF-8"?>
<pool base-path="/test4" name="apex" workspace-id="arranje"/>
If I try in the browser the URL http://localhost:8082/apex/test4, it sadly enough raises the 404 - Not found error.
So I activated the options debug.debugger and debug.printDebugToScreen in the default.xml.
The browser now shows:
Oracle Application Express Listener
404 - Not found No candidate found for: GET test4 test4 not found
(test4 is the base-path I configured)
The command-box where the standalone listener is started, is not showing any extra debug information.
I have the same experience. I can connect to the database of the inital setup but then I try to create a second DB connection with
Create the connection
java -jar apex.war setup --database edwdev1
Sep 28, 2012 5:08:04 PM oracle.dbtools.common.config.file.ConfigurationFolder logConfigFolder
INFO: Using configuration folder: /space/sw/oracle/products/apex/2.0.0/config/apex
Enter the name of the database server [localhost]:ddb001-v.maximusbchealth.local
Enter the database listen port :1521
Enter 1 to specify the database service name, or 2 to specify the database SID :1
Enter the database service name:apex_edwdev1.maximusbc.ca
Enter the database user name [APEX_PUBLIC_USER]:APEX_PUBLIC_USER
Enter the database password for APEX_PUBLIC_USER:
Enter 1 to enter passwords for the RESTful Services database users (APEX_LISTENER,APEX_REST_PUBLIC_USER), 2 to use the same password as used for APEX_PUBLIC_USER or, 3 to skip this step :3
Sep 28, 2012 5:10:12 PM oracle.dbtools.common.config.file.ConfigurationFiles update
INFO: Updated configurations: apex_al, apex_rt, apex, edwdev1, edwdev1_al, edwdev1_rt
Then I create a routing based on theRequest Path Prefix:
I found a solution that works for me but don't ask my why.
When you run
java -jar apex.war setup --database abc
you will get a file <config_dir>/apex/conf/abc.xml. If I compare that with the inital config file ( <config_dir>/apex/conf/apex.xml)
I can see that a lot of properties are missing in the new file. The new file only has db.password, db.servicename, db.username and db.hostname. In comparison the
apex.xml file has about 43 properties. So I:
cp abc.xml abc.xml.old
cp apex.xml abc.xml
=> overwrite the db.password, db.servicename, db.username and db.hostname properties in the new abc.xml with the values from the back up abc.xml.old
Restart the Managed Server through the Weblogic Server Console.
I have done this in two environment and it has worked in both. I hope this will work for you.
Yep. The Apex Listener with Multiple Database Connections lets you consolidate the connection point so you don't need a separate web server or web application for each Apex install. The database you point to still needs to have the Apex schemas installed in it.