UPDATE: I've sorted out the classpath loading issues regarding the patches. See the EAR creation section.
I'm editing this original post to update it with the final resolution so all the steps are in one place.
Why Websphere? Because that is what we run as our standard app server. Maybe I'll give up if I can't resolve all the issues. But below is a comprehensive list of steps to get the esb running on Websphere 6.1.
BUT, I am unable to get to the wso2 esb admin console. This is where I need help! I've tried various ports but there is no response, as if the service didn't come up. I'll follow this post with a log. RESOLUTION: use the latest build from the wso2 esb. I tested with 2008-06-29. There is a fix to the startup servlet.
Deploying wso2 esb to websphere 6.1
First, create an EAR for Websphere:
In RAD 7 create a blank Web App Project and associated EAR: wso2esb, wso2esbEAR
Turn off xml, xsl, and dtd validation in the project properties
Don't try to deploy this to websphere from within RAD!
Unzip the binary distribution of wso2
Import the "webapp" directory into the RAD project WebContent folder, choose overwrite existing resources without warning.
Make sure the classes dir in WEB-INF is empty. The contents will be in the working dir of the websphere profile.
MOVE the WEB-INF/lib/patches and WEB-INF/lib/endorsed directories to the root of the EAR - these jars must be loaded first by the classloader.
MOVE the WEB-INF/lib contents to a new EAR directory called "esb" (this new directory is helpful to keep the jars organized rather than putting them in the root of the EAR).
Edit the META-INF/MANIFEST.MF to include all the jars in the EAR. ATTENTION: Make sure the files in the EAR/patches folder are FIRST in the MANIFEST Class-Path so that they will load in the correct order.. Example:
Manifest-Version: 1.0
Class-Path: axiom-api-1.2.7-001.jar
axis2-clustering-1.4-001.jar
wso2adminui-2.3.jar
patch_sevlet.jar
etc... (about 130 more jars listed)
(Optional) Add this file to the wso2esb/src directory (you may need to use the RAD7 resources view to do this):
common-logging.properties
Contents:
priority=1
org.apache.commons.logging.LogFactory=org.apache.commons.logging.impl.LogFactoryImpl
This will allow the Log4j to be used for the application rather than the websphere logging
http://www-1.ibm.com/support/docview.wss?uid=swg27004610
(I am a bit uncertain about this point since all the jars were put in the EAR it may not matter)
Edit EAR deployment descriptor. Deployment TAB:
wso2esbEAR classloader mode: PARENT LAST
war classloader policy: MODULE
wso2esb classloader mode: PARENT LAST (to allow patches to load first)
Export the EAR
Then deploy to websphere 6.1
Create WAS 6.1 profile
Make note of the ports. They can be found in the profile/config/cells/cellname/nodes/nodename/serverindex.xml WC_defaulthost, and WC_defaulthost_secure
Set the java temp directory to a unique directory
-Djava.io.tmpdir=/tmp/ctmwsgatewayout
There are a few artifacts that are created during runtime which would collide if multiple esbs were run on the same server:
/tmp/_Axis2 directory
/tmp/javasharedresources directory
/tmp/ep.jacl empty file
Set property (at least in WAS 6.1.0.13) otherwise you get "Error 403: SRVE0190E: File not found: " errors in the browser (servlet filter is trying to forward to a file that does not exist). http://www-01.ibm.com/support/docview.wss?uid=swg1PK65408
Add this to the "Server - Web Container - custom properties" (server.xml) in the <components xmi:type="applicationserver.webcontainer:WebContainer"
<properties xmi:id="Property_1213963315728" name="com.ibm.ws.webcontainer.invokefilterscompatibility" value="true" description="To make the filter invoke on a request without a servlet mapping" required="false"/>
Create a working directory somewhere and configure Websphere JVM to use it.
For this example it will exist under the profile dir aka. USER_INSTALL_ROOT, and we'll call it WorkingDir
<processDefinitions xmi:type="processexec:JavaProcessDef" xmi:id="JavaProcessDef_1212583346049" workingDirectory="${USER_INSTALL_ROOT}/WorkingDir" executableTargetKind="JAVA_CLASS" executableTarget="com.ibm.ws.runtime.WsServer">
Create a sub dir in WorkingDir called webapp and create these directories in it:
logs for Log4j
derby for new derby distribution
Unzip the binary distribution for wso2 esb to a temporary dir
Copy these dires from the unzipped distribution to the WorkingDir
registry
repository
samples
webapp
In the webapp REMOVE THE webapp/WEB-INF/lib dir to save space. The jars are all in the EAR created above (about 130!).
Change the working directory of the Websphere 6.1 server to the newly created WorkingDir above
server.xml example. This puts the working directory just under the WAS Profile dir in a dir called WorkingDir:
<processDefinitions xmi:type="processexec:JavaProcessDef" xmi:id="JavaProcessDef_1212583346049" workingDirectory="${USER_INSTALL_ROOT}/WorkingDir" executableTargetKind="JAVA_CLASS" executableTarget="com.ibm.ws.runtime.WsServer">
Change the server.xml to include the /WorkingDir/webapp/WEB-INF/classes dir
<classpath><absolute path>/WorkingDir/webapp/WEB-INF/classes</classpath>
Specifically the Hibernate configuration must be in the class path as
conf/wso2esb.hibernate.cfg.xml
Configure log4j
Set JVM property
<systemProperties xmi:id="Property_1213125579199" name="log4j.configuration" value="file:webapp/WEB-INF/classes/conf/log4j.properties" required="false"/>
(optional) Websphere comes installed with Derby in the root (Websphere/Derby). This is common across ALL websphere profiles.
One option is to use the existing Websphere derby started by websphere. To do that, change this server.xml configuration to false:
<StartEmbeddedDerby>false</StartEmbeddedDerby>
Option two is to set up Derby to run in the profile/server JVM with independent settings and database directories
Create dir WorkingDir/derby
Copy the wso2esb-1.7/webapp/WEB-INF/classes/conf/derby.properties file to WorkingDir/derby
Change these properties as desired:
derby.drda.portNumber=21528
derby.drda.traceDirectory=../logs
derby.stream.error.file=../logs/derby.log
derby.infolog.append=true
Add the following system property to the JVM to point to the new "derby home" dir:
<systemProperties xmi:id="Property_1213112824074" name="derby.system.home" value="<absolute location>/WorkingDir/derby" required="false"/>
Configure AXIS
This config file is located by path relative to the working dir
WorkingDir/webapp/WEB-INF/classes/conf
but can be overridden by the JVM property
<systemProperties xmi:id="Property_1213125304168" name="axis2.xml" value="webapp/WEB-INF/classes/conf/axis2.xml" required="false"/>
<systemProperties xmi:id="Property_1213125318433" name="axis2.repo" value="repository" required="false"/>
axis2.xml configurations relate mostly to ports:
<transportReceiver name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOListener">
<parameter name="port" locked="false">28080</parameter>
<parameter name="non-blocking" locked="false">true</parameter>
</transportReceiver>
<transportReceiver name="https" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSSLListener">
<parameter name="port" locked="false">28443</parameter>
<parameter name="non-blocking" locked="false">true</parameter>
<transportReceiver name="admin/https" class="org.wso2.esb.transport.tomcat.HttpsTransportListener">
<parameter name="port" locked="false">29443</parameter>
<!--<parameter name="non-blocking" locked="false">true</parameter>-->
</transportReceiver>
KeyStore/Location should be absolute paths. There are four of them:
<Location>{put your absolute path here to working dir}/webapp/WEB-INF/classes/conf/identity.jks</Location>
Configure Hibernate
NOTE: configuration in classpath set above located WorkingDir/webapp/WEB-INF/classes/conf/wso2esb.hibernate.cfg.xml
The wso2esb.hibernate.cfg.xml configuration is mostly related to the derby config above:
<property name="connection.url">jdbc:derby://localhost:21528/database/WSO2ESB_DATABASE;create=true</property>
Configure Apache Synapse
WorkingDir/webapp/WEB-INF/classes/conf/synapse.xml
There may be some port information in it
<systemProperties xmi:id="Property_1212779662857" name="synapse.xml" value="<absolute path>/webapp/WEB-INF/classes/conf/synapse.xml" required="false"/>
Configure wso2 esb
Set the JVM property esb.home to the WorkingDir that contains all the directories from the binary distrubution above.
<systemProperties xmi:id="Property_1212592993985" name="esb.home" value="<absolute path>/WorkingDir" description="pk set for wso2" required="false"/>
(optional) Config file location can be overridden by the esb.xml JVM Property
esb.xml=webapp/WEB-INF/classes/conf/server.xml
Properties to change for port configuration:
<Ports.JMX>21099</Ports.JMX>
<AdminConsole><Port>9463</Port> <!-- this MUST be the secure port for the Websphere App server ! -->
<RMIRegistryPort>21099</RMIRegistryPort> <!-- RMI Registry port used for JMX -->
<HTTPPort>28280</HTTPPort> <!-- HTTP port used by the underlying Axis2/Synapse -->
<HTTPSPort>28243</HTTPSPort> <!-- HTTPS port used by the underlying Axis2/Synapse -->
<DerbyPort>21528</DerbyPort> <!-- Derby database port -->
NOTE: This is not sued in wso2 esb 1.7! Configure wso2 esb admin console javascript:
WorkingDir/webapp/js/main.js
var httpsPort = 29443; <<<---- this port should be the same as the <AdminConsole><Port>?
Configure wso2 esb repository
WorkingDir/webapp/WEB-INF/classes/conf/registry.xml
Change the port for derby
<url>jdbc:derby://localhost:21528/database/WSO2REGISTRY_DB;create=true</url>
Install wso2esbEAR created in RAD7 Link
Restart Websphere
Look in the WorkingDir/logs for the following files:
derby.log - derby service
esb_service.log
esb_trace.log
wso2-esb.log
NOTE: the SystemOut.log from Websphere will include some esb logging, especially if you use the Websphere logger rather than Log4j (see above)
Access the wso2 esb admin console (you must use the secure port):
https://localhost:9463/wso2esb/
NOTE: we prefer to use the older file based registry rather than the embedded wso2 database registry. To do that we configured the synapse.xml as follows:
<syn:registry provider="org.wso2.esb.registry.ESBRegistry">
<syn:parameter name="root">file:registry/</syn:parameter>
<syn:parameter name="cachableDuration">15000</syn:parameter>
</syn:registry>
This reduces the need for derby a bit, eliminating one database.
Bookmark/Search this post with:
Deploying wso2 esb to Websphere
Hi
Thanks lots for your well try !!.
Before ESB 1.7 release , I also tried to deploy the ESB on websphere 6.1 and ended up with same result as you have gotten. ESB was running without errors but admin console wasn't get. I hadn't time to go ahead as I was busy with ESB release at that time. It seems it is with a issue with servlet filters. We have a filter (AdminServletFilter) which writes generated html contents. Please read [1] and [2]. I will try as I can to get work ESB on websphere.
[1] http://www.dhptech.com/node/21
[2]http://greatwebguy.com/programming/java/urlrewritefilter-servlet-filter-problem-in-websphere-6105-and-greater/
Thanks
Indika
logs
Below are my logs. I hope you find something that would get this to work. I'll look at your links.
wso2-esb.log
2008-06-17 11:26:59,243 [-] [server.startup : 2] INFO ServiceBusManager Starting the JMX Connector
2008-06-17 11:26:59,243 [-] [server.startup : 2] INFO ServiceBusConfiguration Configuration loading from : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\server.xml
2008-06-17 11:27:00,055 [-] [server.startup : 2] INFO ServiceBusManager JMX consoles can connect to : service:jmx:rmi:///jndi/rmi://48.123.12.7:21099/esb
2008-06-17 11:27:00,086 [-] [server.startup : 2] INFO ServiceBusManager Starting the WSO2 Enterprise Service Bus..
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServiceBusManager Database server started on 127.0.0.1 over port 21528
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using Synapse home as : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using the Axis2 Repository : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\repository
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using the axis2.xml : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\axis2.xml
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager The server name was not specified, defaulting to : hostname
2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager The timeout handler will run every : 15s
2008-06-17 11:27:03,899 [-] [server.startup : 2] INFO SynapseInitializationModule Initializing Synapse at : Tue Jun 17 11:27:03 EDT 2008
2008-06-17 11:27:03,915 [hostname] [server.startup : 2] INFO SynapseInitializationModule Loading mediator extensions...
2008-06-17 11:27:05,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Initializing the Synapse configuration ...
2008-06-17 11:27:06,383 [hostname] [server.startup : 2] INFO XMLConfigurationBuilder Generating the Synapse configuration model by parsing the XML configuration
2008-06-17 11:27:15,899 [hostname] [server.startup : 2] INFO SynapseConfigurationBuilder Loaded Synapse configuration from : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\synapse.xml
2008-06-17 11:27:15,930 [hostname] [server.startup : 2] INFO SynapseInitializationModule Deploying the Synapse service..
2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Synapse server name : hostname
2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Deploying Proxy services...
2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Synapse initialized successfully...!
2008-06-17 11:27:15,961 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLSender Loading Identity Keystore from : webapp/WEB-INF/classes/conf/identity.jks
2008-06-17 11:27:15,961 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLSender Loading Trust Keystore from : webapp/WEB-INF/classes/conf/trust.jks
2008-06-17 11:27:16,024 [hostname] [server.startup : 2] INFO HttpCoreNIOSender HTTPS Sender starting
2008-06-17 11:27:16,039 [hostname] [server.startup : 2] INFO HttpCoreNIOSender HTTP Sender starting
2008-06-17 11:27:16,118 [hostname] [server.startup : 2] INFO VFSTransportSender VFS Sender started
2008-06-17 11:27:17,211 [hostname] [server.startup : 2] INFO JMSSender JMS Sender started
2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO ServerManager Starting transport admin/https on port 29444
2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO ServerManager Starting transport https on port 28243
2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLListener Loading Identity Keystore from : webapp/WEB-INF/classes/conf/identity.jks
2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLListener Loading Trust Keystore from : webapp/WEB-INF/classes/conf/trust.jks
2008-06-17 11:27:18,774 [hostname] [server.startup : 2] INFO HttpCoreNIOListener HTTPS Listener starting on port : 28243
2008-06-17 11:27:18,774 [hostname] [server.startup : 2] INFO ServerManager Starting transport http on port 28280
2008-06-17 11:27:18,836 [hostname] [server.startup : 2] INFO HttpCoreNIOListener HTTP Listener starting on port : 28280
2008-06-17 11:27:18,836 [hostname] [server.startup : 2] INFO ServerManager Starting transport vfs
2008-06-17 11:27:19,196 [hostname] [server.startup : 2] INFO VFSTransportListener VFS Listener started
2008-06-17 11:27:19,211 [hostname] [server.startup : 2] INFO ServerManager Starting transport mailto
2008-06-17 11:27:19,211 [hostname] [server.startup : 2] INFO MailTransportListener MAILTO Listener started
2008-06-17 11:27:19,227 [hostname] [server.startup : 2] INFO ServerManager Ready for processing
2008-06-17 11:27:25,789 [hostname] [server.startup : 2] INFO ServiceBusManager [ESB] Start request completed
===========================================================================================================
websphere systemout.log
************ Start Display Current Environment ************
WebSphere Platform 6.1 [BASE 6.1.0.2 cf20633.22]
Host Operating System is Windows XP, version 5.1 build 2600 Service Pack 2
Java version = J2RE 1.5.0 IBM J9 2.3 Windows XP x86-32 j9vmwi3223-20060504 (JIT enabled)
J9VM - 20060501_06428_lHdSMR
JIT - 20060428_1800_r8
GC - 20060501_AA, Java Compiler = j9jit23, Java VM name = IBM J9 VM
....
[6/17/08 11:26:49:555 EDT] 00000013 ApplicationMg A WSVR0200I: Starting application: wso2esbEAR
[6/17/08 11:26:49:555 EDT] 00000013 ApplicationMg A WSVR0204I: Application: wso2esbEAR Application build level: Unknown
[6/17/08 11:26:58:243 EDT] 00000013 ResourceMgrIm I WSVR0049I: Binding DefaultEJBTimerDataSource as jdbc/DefaultEJBTimerDataSource
[6/17/08 11:26:58:368 EDT] 00000013 WebGroup A SRVE0169I: Loading Web Module: WSO2 ESB.
[6/17/08 11:26:59:243 EDT] 00000013 SystemOut O 2008-06-17 11:26:59,243 [-] [server.startup : 2] INFO ServiceBusManager Starting the JMX Connector
[6/17/08 11:26:59:243 EDT] 00000013 SystemOut O 2008-06-17 11:26:59,243 [-] [server.startup : 2] INFO ServiceBusConfiguration Configuration loading from : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\server.xml
[6/17/08 11:26:59:711 EDT] 00000013 SystemOut O 0
[6/17/08 11:26:59:727 EDT] 00000013 SystemOut O 3
[6/17/08 11:26:59:727 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:743 EDT] 00000013 SystemOut O 8
[6/17/08 11:26:59:743 EDT] 00000013 SystemOut O 0
[6/17/08 11:26:59:743 EDT] 00000013 SystemOut O 0
[6/17/08 11:26:59:743 EDT] 00000013 SystemOut O 0
[6/17/08 11:26:59:758 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:758 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:758 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:774 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:774 EDT] 00000013 SystemOut O 1
[6/17/08 11:26:59:774 EDT] 00000013 SystemOut O 0
[6/17/08 11:26:59:774 EDT] 00000013 SystemOut O 0
[6/17/08 11:27:00:055 EDT] 00000013 SystemOut O 2008-06-17 11:27:00,055 [-] [server.startup : 2] INFO ServiceBusManager JMX consoles can connect to : service:jmx:rmi:///jndi/rmi://48.123.12.7:21099/esb
[6/17/08 11:27:00:055 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.ServiceBusControl
[6/17/08 11:27:00:071 EDT] 00000013 SystemOut O 7
[6/17/08 11:27:00:086 EDT] 00000013 SystemOut O 2008-06-17 11:27:00,086 [-] [server.startup : 2] INFO ServiceBusManager Starting the WSO2 Enterprise Service Bus..
[6/17/08 11:27:01:821 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServiceBusManager Database server started on 127.0.0.1 over port 21528
[6/17/08 11:27:01:821 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using Synapse home as : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17
[6/17/08 11:27:01:821 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using the Axis2 Repository : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\repository
[6/17/08 11:27:01:821 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager Using the axis2.xml : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\axis2.xml
[6/17/08 11:27:01:821 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager The server name was not specified, defaulting to : hostname
[6/17/08 11:27:01:836 EDT] 00000013 SystemOut O 2008-06-17 11:27:01,821 [-] [server.startup : 2] INFO ServerManager The timeout handler will run every : 15s
[6/17/08 11:27:03:899 EDT] 00000013 SystemOut O 2008-06-17 11:27:03,899 [-] [server.startup : 2] INFO SynapseInitializationModule Initializing Synapse at : Tue Jun 17 11:27:03 EDT 2008
[6/17/08 11:27:03:915 EDT] 00000013 SystemOut O 2008-06-17 11:27:03,915 [hostname] [server.startup : 2] INFO SynapseInitializationModule Loading mediator extensions...
[6/17/08 11:27:05:961 EDT] 00000013 SystemOut O 2008-06-17 11:27:05,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Initializing the Synapse configuration ...
[6/17/08 11:27:06:383 EDT] 00000013 SystemOut O 2008-06-17 11:27:06,383 [hostname] [server.startup : 2] INFO XMLConfigurationBuilder Generating the Synapse configuration model by parsing the XML configuration
[6/17/08 11:27:15:899 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,899 [hostname] [server.startup : 2] INFO SynapseConfigurationBuilder Loaded Synapse configuration from : E:\RAD7\RAD\runtimes\base_v61\profiles\AppSrv02\WorkingDir17\webapp\WEB-INF\classes\conf\synapse.xml
[6/17/08 11:27:15:930 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,930 [hostname] [server.startup : 2] INFO SynapseInitializationModule Deploying the Synapse service..
[6/17/08 11:27:15:946 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Synapse server name : hostname
[6/17/08 11:27:15:946 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Deploying Proxy services...
[6/17/08 11:27:15:946 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,946 [hostname] [server.startup : 2] INFO SynapseInitializationModule Synapse initialized successfully...!
[6/17/08 11:27:15:961 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,961 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLSender Loading Identity Keystore from : webapp/WEB-INF/classes/conf/identity.jks
[6/17/08 11:27:15:961 EDT] 00000013 SystemOut O 2008-06-17 11:27:15,961 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLSender Loading Trust Keystore from : webapp/WEB-INF/classes/conf/trust.jks
[6/17/08 11:27:16:024 EDT] 00000013 SystemOut O 2008-06-17 11:27:16,024 [hostname] [server.startup : 2] INFO HttpCoreNIOSender HTTPS Sender starting
[6/17/08 11:27:16:024 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:16:024 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:16:039 EDT] 00000013 SystemOut O 2008-06-17 11:27:16,039 [hostname] [server.startup : 2] INFO HttpCoreNIOSender HTTP Sender starting
[6/17/08 11:27:16:039 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:16:039 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:16:039 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:16:055 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:16:118 EDT] 00000013 SystemOut O 2008-06-17 11:27:16,118 [hostname] [server.startup : 2] INFO VFSTransportSender VFS Sender started
[6/17/08 11:27:17:196 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:17:196 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:17:211 EDT] 00000013 SystemOut O 2008-06-17 11:27:17,211 [hostname] [server.startup : 2] INFO JMSSender JMS Sender started
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO ServerManager Starting transport admin/https on port 29444
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO ServerManager Starting transport https on port 28243
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLListener Loading Identity Keystore from : webapp/WEB-INF/classes/conf/identity.jks
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,758 [hostname] [server.startup : 2] INFO HttpCoreNIOSSLListener Loading Trust Keystore from : webapp/WEB-INF/classes/conf/trust.jks
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:18:758 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:18:774 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,774 [hostname] [server.startup : 2] INFO HttpCoreNIOListener HTTPS Listener starting on port : 28243
[6/17/08 11:27:18:774 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,774 [hostname] [server.startup : 2] INFO ServerManager Starting transport http on port 28280
[6/17/08 11:27:18:805 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:18:821 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:18:836 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,836 [hostname] [server.startup : 2] INFO HttpCoreNIOListener HTTP Listener starting on port : 28280
[6/17/08 11:27:18:836 EDT] 00000013 SystemOut O 2008-06-17 11:27:18,836 [hostname] [server.startup : 2] INFO ServerManager Starting transport vfs
[6/17/08 11:27:18:836 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:18:836 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:19:196 EDT] 00000013 SystemOut O 2008-06-17 11:27:19,196 [hostname] [server.startup : 2] INFO VFSTransportListener VFS Listener started
[6/17/08 11:27:19:211 EDT] 00000013 SystemOut O 2008-06-17 11:27:19,211 [hostname] [server.startup : 2] INFO ServerManager Starting transport mailto
[6/17/08 11:27:19:211 EDT] 00000013 SystemOut O org.apache.synapse.transport.base.TransportView
[6/17/08 11:27:19:211 EDT] 00000013 SystemOut O 14
[6/17/08 11:27:19:211 EDT] 00000013 SystemOut O 2008-06-17 11:27:19,211 [hostname] [server.startup : 2] INFO MailTransportListener MAILTO Listener started
[6/17/08 11:27:19:227 EDT] 00000013 SystemOut O 2008-06-17 11:27:19,227 [hostname] [server.startup : 2] INFO ServerManager Ready for processing
[6/17/08 11:27:25:649 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.ServerStatusView
[6/17/08 11:27:25:649 EDT] 00000013 SystemOut O 5
[6/17/08 11:27:25:696 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.ServerStatisticsView
[6/17/08 11:27:25:696 EDT] 00000013 SystemOut O 6
[6/17/08 11:27:25:696 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.SequenceStatisticsView
[6/17/08 11:27:25:711 EDT] 00000013 SystemOut O 6
[6/17/08 11:27:25:743 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.ProxyServiceStatisticsView
[6/17/08 11:27:25:743 EDT] 00000013 SystemOut O 6
[6/17/08 11:27:25:758 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.EndpointStatisticsView
[6/17/08 11:27:25:758 EDT] 00000013 SystemOut O 6
[6/17/08 11:27:25:774 EDT] 00000013 SystemOut O org.wso2.esb.jmx.mbean.SynapseServiceStatisticsView
[6/17/08 11:27:25:774 EDT] 00000013 SystemOut O 5
[6/17/08 11:27:25:789 EDT] 00000013 SystemOut O 2008-06-17 11:27:25,789 [hostname] [server.startup : 2] INFO ServiceBusManager [ESB] Start request completed
[6/17/08 11:27:25:852 EDT] 00000013 ServletWrappe I SRVE0242I: [wso2esbEAR] [/wso2esb] [ESBStartUpServlet]: Initialization successful.
[6/17/08 11:27:25:977 EDT] 00000013 VirtualHost I SRVE0250I: Web Module WSO2 ESB has been bound to default_host[*:9094,*:80,*:9459,*:5071,*:5070,*:443].
[6/17/08 11:27:26:008 EDT] 00000013 ApplicationMg A WSVR0221I: Application started: wso2esbEAR
[6/17/08 11:27:27:180 EDT] 0000000a TCPChannel I TCPC0001I: TCP Channel TCP_1 is listening on host * (IPv4) port 9074.
[6/17/08 11:27:27:227 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain WCInboundAdmin.
[6/17/08 11:27:27:274 EDT] 0000000a TCPChannel I TCPC0001I: TCP Channel TCP_2 is listening on host * (IPv4) port 9094.
[6/17/08 11:27:27:289 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain WCInboundDefault.
[6/17/08 11:27:27:477 EDT] 0000000a TCPChannel I TCPC0001I: TCP Channel TCP_3 is listening on host * (IPv4) port 9057.
[6/17/08 11:27:27:633 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain WCInboundAdminSecure.
[6/17/08 11:27:27:696 EDT] 0000000a TCPChannel I TCPC0001I: TCP Channel TCP_4 is listening on host * (IPv4) port 9459.
[6/17/08 11:27:27:711 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain WCInboundDefaultSecure.
[6/17/08 11:27:27:742 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain SOAPAcceptorChain1.
[6/17/08 11:27:28:086 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain SOAPAcceptorChain2.
[6/17/08 11:27:28:117 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain SOAPAcceptorChain3.
[6/17/08 11:27:28:133 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain SOAPAcceptorChain4.
[6/17/08 11:27:28:180 EDT] 00000013 SchedulerServ I SCHD0077I: The Scheduler Service is starting the Schedulers.
[6/17/08 11:27:28:258 EDT] 00000013 SchedulerServ I SCHD0078I: The Scheduler Service has completed starting the Schedulers.
[6/17/08 11:27:28:305 EDT] 0000000a RMIConnectorC A ADMC0026I: The RMI Connector is available at port 2823
[6/17/08 11:27:28:586 EDT] 00000016 WorkSpaceMana A WKSP0500I: Workspace configuration consistency check is false.
[6/17/08 11:27:29:461 EDT] 0000000a WsServerImpl A WSVR0001I: Server server1 open for e-business
the port for the admin console appears to be unused
One more comment, it appears that the port for the admin console is not in use. When I try the url
http: // localhost:29444/esb (or 9443, or whatever port set above) i get server not found.
In windows cmd I check netstat -a and the port is not in use.
With the 1.7 release, is the definition of the admin port in the axis2.xml?
the port for the admin console appears to be unused
'ConsolePort' parameter in the 'tomcat.properties' only is used by standalone ESB server. If you deployed ESB on a application server, then it's https port will be used. Then , it becomes just an another web application in the application server. Then, it can be accessed same as any other web application. But you have to use 'https' transport.Please make sure it.
Please make sure it. The [1] article describes how WSO2 WSAS deploy on websphere. Please read it too.
[1] http://wso2.org/library/2735
Indika
Isn't this a problem with WebSphere?
Indika
I remember you telling me about a known problem with servlet filters on WebSphere, which has a fix - but we couldn't deploy it as some crazy code was first checking if the machine was an IBM system!! and our's wastn't. Anyway we were never able to install WebSphere on Linux either, even the simple installation fails to complete sucessfully
If any of our users run WebSphere 6.1 on Linux, can you please help us with instruction to set it up? That will help us to continue testing with future releases
asankha
ports
I have read the article http://wso2.org/library/2735 and found one part that may be relevant. Towards the bottom there is a section on ports.
I have the following observations:
webapp/WEB-INF/classes/conf/axis2.xml has these ports configured:
<transportReceiver name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOListener">
<parameter name="port" locked="false">28280</parameter>
<transportReceiver name="https" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSSLListener">
<parameter name="port" locked="false">28243</parameter>
webapp/WEB-INF/classes/conf/server.xml has these ports configured:
<HTTPPort>28280</HTTPPort> <!-- HTTP port used by the underlying Axis2/Synapse -->
<HTTPSPort>28243</HTTPSPort> <!-- HTTPS port used by the underlying Axis2/Synapse -->
my websphere profile serverindex.xml has these ports:
<specialEndpoints xmi:id="NamedEndPoint_1212583345493" endPointName="WC_defaulthost">
<endPoint xmi:id="EndPoint_1212583345493" host="*" port="9094"/>
<specialEndpoints xmi:id="NamedEndPoint_1212583345496" endPointName="WC_defaulthost_secure">
<endPoint xmi:id="EndPoint_1212583345496" host="*" port="9459"/>
I will try to make them all in sync and see what happens.
And what about webapp/js/main.js? Is this relevant?
var httpsPort = 29443;
Pete The main.js one is not
Pete
The main.js one is not relevant anymore.. we will remove that for future..
thanks
asankha
ports - follow up
Changing the ports to the ports found in the websphere serverindex.xml was not good.
[6/18/08 14:10:08:573 EDT] 00000012 ApplicationMg A WSVR0221I: Application started: wso2esbEAR
[6/18/08 14:10:08:901 EDT] 0000000a TCPChannel I TCPC0001I: TCP Channel TCP_1 is listening on host * (IPv4) port 9074.
[6/18/08 14:10:08:932 EDT] 0000000a WSChannelFram A CHFW0019I: The Transport Channel Service has started chain WCInboundAdmin.
[6/18/08 14:10:08:995 EDT] 0000000a TCPPort E TCPC0003E: TCP Channel TCP_2 initialization failed. The socket bind failed for host * and port 9094. The port may already be in use.
[6/18/08 14:10:09:010 EDT] 0000000a WSChannelFram E CHFW0034W: The Transport Channel Service detected transport chain WCInboundDefault failed. The service will retry to start chain WCInboundDefault every 5000 milliseconds for up to 60 attempts.
The ports in serverindex.xml are used by websphere, so I need to specify new ports in the axis2.xml and server.xml (wso2/esb). My impression is that axis is going to open its own ports, regardless of the websphere application server. But to get back to my original problem, this admin port does NOT get used. Something is prevending axis (or whatever) from opening the port, etc.
And just to clarify, the admin port appears to be configured in the axis2.xml
<transportReceiver name="admin/https" class="org.wso2.esb.transport.tomcat.HttpsTransportListener">
<parameter name="port" locked="false">29444</parameter>
<parameter name="non-blocking" locked="false">true</parameter>
</transportReceiver>
And that port does not respond, nor does it appear to be in use according to Windows (netstat -a).
Pete >And just to clarify,
Pete
>And just to clarify, the admin port appears to be configured in the axis2.xml
The port parameter is commented out in the 1.7 and would be removed soon.. and I can confirm that its not used from axis2.xml
What is your patch level for WAS 6.1? Have you installed the patch for Servlet filters? We were not able to install it on our Windows boxes, as it looked for an "IBM" machine and refuse to install on other hardware!
asankha
Servlet Filter loading order
I remember we faced the same issue -- admin console not working -- when deploying WSO2 WSAS in Websphere sometime back. I think the admin console was not working because filters were not initialized before servlets and this made an initialization not happening because of that. (http://markmail.org/message/ufggprq3ndzxocbc)
A workaround was done in Admin UI library version used by WSAS to fix it in WSO2 WSAS 2.1. WSO2 ESB uses a prior version of the same UI library I think.
Got it works
Finally , I got it works. Upul was correct, there was an issue in our filters. Now , those are fixed. Thanks Lots Upul for your help.
Fix is in the current trunk SVN, therefore, you have to build the ESB SVN trunk or wait for nightly build.
Just deploy the binary as you did before . Then, admin console is working on the port of application server's https port (Not application sever console port). If you use websphere default setting , then you can access the ESB admin console from https://localhost:9443/esb.
Please refers to the article on [1] which was written by the Upul. Please configure the sever (Including Web container properties ) according to the above article except Database things.
I have got it works. if you are unable to get it works , please let me know.
[1]http://wso2.org/library/2735
Thanks
Indika
will give it a try
I did some of my own testing (not with wso2 code) and found that servlet filters do work in websphere 6.1.0.17, and I am using this technote as a guide.
http://www-1.ibm.com/support/docview.wss?uid=swg1PK31377
But I also found that the wso2 esb servlet filter did not work. So I happy you made some progress and will give it a try.
Setps I did
Hi
Here is what I did
Extract the distribution - (Build from trunk)
Change jks file locations in the axis2.xml to absolute ones. (4 locations)
I was unable to getting stared derby server inside websphere, therefore , I start an external derby server and it's default port was 1527. I was changed it to 1528 because we use that port(1528) by default. I followed bellow guide
http://db.apache.org/derby/docs/dev/adminguide/tadmincbdjhhfd.html#tadmincbdjhhfd
In addition to avoid starting derby inside ESB , edit parameter in the server.xml (esb.home/webapp/WEB-INF/classes/conf/) - <StartEmbeddedDerby>false</StartEmbeddedDerby>
set the esb home in web.xml - example C:\esb-1.7\
create a war file to include all files under $esb.home/webapp directory.
Deploy it through websphere web console.
I have to configure websphere according to the section 'Configuring IBM WebSphere Application Server' on article http://wso2.org/library/2735 (Upul's one)
After saving each changes just restart the server
Console is available on https://localhost:9443/esb
Done some smocks tests and seems work fine.
Thanks
Indika
partial success
I rebuilt the EAR/WAR using the 2008-06-29 nightly build.
One other configuration to the WAR: the lib/patches are supposed to be loaded before the other jars in the lib. To achieve this I did the following:
Copy the WEB-INF/lib/patches contents to the root of the EAR project
Edit the META-INF/MANIFEST.MF to include all the patches files from the EAR
Class-Path: axiom-api-1.2.7-001.jar
axis2-clustering-1.4-001.jar
So now when I invoke the application:
http://localhost:9095/wso2esb/
(9095 is the port for the app, and wso2esb was the name of the context root/war that I gave it)
Then I try to log in I get this message:
The service cannot be found for the endpoint reference (EPR) http://localhost:9095/wso2esb/soap/__LoginAdmin/login
wso2 esb server.xml was configured
<HTTPPort>28280</HTTPPort> <!-- HTTP port used by the underlying Axis2/Synapse -->
axis2.xml
<transportReceiver name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOListener">
<parameter name="port" locked="false">28280</parameter>
<parameter name="non-blocking" locked="false">true</parameter>
</transportReceiver>
When I look at http://localhost:28280/soap/ it shows:
Deployed services
So for some reason the login page is looking at the wrong port for the login service. How do I configure that correctly?
axis ports?
Although the esb server.xml and axis2.xml can be configured with ports for the axis services, the admin console apparently is assuming the same port for the services as the admin console. Is that right?
The javascript to set the serverURL in javascript appears to be:
webapp\extensions\core\js\esb.js
function init() {
URL = locationString.substring(0, locationString.lastIndexOf('/'));
// Service URL parsing
serverURL = URL + SERVICE_CONTEXT;
But if I configured the esb server.xml and the axis2.xml to use the same ports as the webapp, there would be a port conflict. So there must be a way to tell the admin console which port to use for services.
Re: Partial Success
Hi pete
Please uses * https * transport. Admin services only can be acceded through the https .
Your http://localhost:9095/wso2esb/ is wrong
and it should be corrected as
https://localhost:xxxx/wso2esb/ where xxxx is https port of websphre application server.
Thanks
Indika
Admin cosole port
Hi
Please add following part to the server.xml if your are changing admin console port
<AdminConsole>
<Port>9443</Port>
</AdminConsole>
Thanks
Indika
It worked!
I added the 9463 to the wso2 esb server.xml
and then I tried the secure Websphere port
https://localhost:9463/wso2esb/
Got the login, and was able to log in successfully!
Thanks for all the help!
Nice to here that
Hi Pete
Nice to here that you have finally got success.
Thanks
Indika
one final question about classloader
In the WEB-INF/lib directory there are two subdirectories:
patches - the note in this dir indicates that these jars should be loaded first.
endorsed - what are these? and how should the application server / jre classloader be configured to load them?
Contents:
xercesImpl-2.8.1.jar
xml-apis-1.3.04.jar
jars inside 'endorsed' have
jars inside 'endorsed' have to be gone to the directory that corresponding to the value of Java specific system property -Djava.endorsed.dirs
This is default to $JAVA_HOME/jre/lib/endorsed
In standalone ESB we sets -Djava.endorsed.dirs=$ESB_HOME/webapp/WEB-INF/lib/endorsed:$JAVA_HOME/jre/lib/endorsed
There may be specific directory on web-sphere.
By the way , if you put these things in the $JAVA_HOME/jre/lib/endorsed ,those are definitely loaded. Here $JAVA_HOME should be Java that web-sphere uses.
patches have to be loaded before any class in the WEB-INF , as they contain fixes for some issues. Jars in the WEB-INF/pathes may not be loaded if ESB deploys as a webapp on websphere (Not standalone). I don't know how patches configure per web applications in websphere. Requirement here is , these jars have to loaded before Jar inside (WEB-INF/lib). (You can do this by get out of patches and put those in WEB-INF/lib with ordering first,so that those will be loaded before others- This may not seem nice)
Thanks
Indika
endorsed
Why do we need these in the endorsed dir?
xercesImpl-2.8.1.jar
xml-apis-1.3.04.jar
I believe Websphere includes them. Is it that Tomcat does not so you need to add them?
Pete The above files are
Pete
The above files are required for the "Validate" mediator to function correctly. If they are setup in the JDK's JAVA/lib/endorsed (or JAVA/jre/lib/endorsed if you have the JRE), or on a path pointed by the endorsed directory system property, they will be found and used correctly. If you do not have any issues with the Validate mediator on WebSphere, you are fine. However, the default standalone distribution we ship uses the lib/endorsed directory and the system property points there.
asankha