Rohit Lal

Greenhorn
+ Follow
since Sep 25, 2003
geocities.com
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Rohit Lal

Sorry Bill,

No idea yet on inter-portlet commmunication. Not delved into that yet. I think there are some examples on the IBM site. A search on Google might throw up the related links.

Rohit
16 years ago
Bill:

Even I have just entered the world of protlets a month back. I'm using the JSR-168 api too. Here's how I would go about explaining portlets:

A portlet application is a web application in itself. A portlet also dishes up web content and in fact uses an api very similar to that of the Servlet api. But it does not inherit/implement anything from the servlet api, mind you. E.g. you have PortletRequest, PortletResponse, PortletRequestDispatcher. etc. etc. doing similar functions as in the servlet api, but they do not inherit from the servlet api. However, there is a major difference between servlets and portlets which I'm going to try to explain below-

A portlet dishes up web content that forms PART not whole of a browser page. A web portal will typically be composed of many portlets, each taking up space on the page. Now comes the interesting part - in a servlet the action and rendering tasks are performing in one go through the service method. i.e. you would call the business validators and do any other tasks before calling the relevant JSP page all through the service() method. this is because the content served by the servlet forms the entire page. so the servlet just processes all the tasks and then serves the content through one service() method.

But, in a portlet, since it renders only part of the browser page, it cannot do this processing and rendering all at one go. This is because, in the case of a portal having say 2 portlets, portlet A and portlet B, a user may perform some action on portlet B resulting in iot needing to be refreshed. But since the entire page will be refreshed, portlet A will also be rendered again. No action was performed on portlet A, yet it was refreshed again. in the case of portlet B, the action was performed on it and then it was rendered again automaticlly. the action on the portlet happens thru the processAction(...) method and the rendering takes place thru the render(...) method. the action changes the state of the portlet, while rendering shows the current state of the portlet.

It is the job of the portlet container to tranlate HTTP into portlet api and vice-versa. So portlets live inside a portlet container and dish out content which is passed on to the portlet container which then translates into HTTP and browser readable format.

Also - just as we have doGet(), doPost() called from the service() method, same way we have in Portlets the doView() and other methods called from the render(...) method

here's a very simple example of a portlet:
HelloPortlet.java
=====================
package hello;

import java.io.*;

import javax.portlet.*;

/**
*
* A sample portlet based on GenericPortlet
*
*/
public class HelloPortlet extends GenericPortlet {

/**
* @see javax.portlet.GenericPortlet#doView(RenderRequest, RenderResponse)
*/
protected void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException {
response.setContentType(request.getResponseContentType());
response.getWriter().println("Hello World");
}

/**
* Process an action request.
*
* @see javax.portlet.Portlet#processAction(ActionRequest, ActionResponse)
*/
public void processAction(ActionRequest request, ActionResponse response) throws PortletException, java.io.IOException {
// Add action request handler here
}
}
============================


web.xml
========
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app id="WebApp_ID">
<display-name>Hello</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<taglib id="PortletTLD">
<taglib-uri>http://java.sun.com/portlet</taglib-uri>;
<taglib-location>/WEB-INF/tld/std-portlet.tld</taglib-location>
</taglib>
</web-app>
===================================



portlet.xml
===========
<?xml version="1.0" encoding="UTF-8"?>
<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" version="1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" id="hello.HelloPortlet.dbff84bf80">
<portlet>
<description>This is the Hello World portlet</description>
<description xml:lang="en">This is the Hello World portlet</description>
<portlet-name>Hello</portlet-name>
<display-name>Hello portlet</display-name>
<display-name xml:lang="en">Hello portlet</display-name>
<portlet-class>hello.HelloPortlet</portlet-class>
<init-param>
<name>wps.markup</name>
<value>html</value>
</init-param>
<expiration-cache>0</expiration-cache>
<supports>
<mime-type>text/html</mime-type>
<portlet-mode>view</portlet-mode>
</supports>
<supported-locale>en</supported-locale>
<portlet-info>
<title>Hello portlet</title>
</portlet-info>
</portlet>
</portlet-app>

=======END==================



Originally posted by William Moore:
Hi,

I am totally new to the world of Portlets, I don't even know how to start though i have set up a workspace and am currently running the HelloWorldPortlet in WSAD 5.1.2 but i need some very basic help on how to code a Portlet using JSR168.

Thanks in advance,
Bill

16 years ago
Thanks Stephan,

I'll work on your tips and let you know as soon as I achieve some milestone.

Thanks for your advice.

Best regards,

Rohit
16 years ago
Hi All,

I've mentioned this problem in a previous posting - I can't seem to get a working example of Struts with JSR-168 portlets. Someone suggested the MVCPortlet framework, but then it's got it's own learning curve. The result is that I'm having to work on the JSP bit without the wonderful Struts tags. I'm having to use for loops and whatnot inside the JSPs - messy. I'm not familiar with JSF and I'm not sure if I should start learning that in an effort to get pre-defined tag libraries for use in portlet JSPs.

So the option I considered was to make my own custom tags and use them for the various dynamic stuff we have on JSPs. A problem crops up: My javabean object with all my form-field values and success/error messages is in the PortletSession object which can be accessed through the 'renderRequest' object on the JSP which is available after placing the <portlet efineObjects/> tag.

I can access renderRequest on the JSP - but how do I access it in the custom tag? Am I on the right track? Is it even possible to use portlet JSPs
with custom tags that need to access portlet-driven information thru the renderRequest object?

Rohit Lal
16 years ago
Hi All,

It's been some time since I have progressed beyond displaying "Hello World" on a JSR-168 portlet and going on to navigation between JSPs and saving information through forms. At this stage I can think of using the data collected and sending it to the business layer.

Trouble is, I need to develop an example using Struts as most of the development in my firm is done using it. I myself am more comfortable with Struts and so am eager to build a portlet using it. I came across an example on IBM's site at this URL:
http://www-128.ibm.com/developerworks/websphere/library/techarticles/0601_patil/0601_patil.html

It requires you to download a zip file which contains several example wars for portlets using Struts. So far so good. But I go on to discover that after importing the wars as projects under RAD v.6, only the ones using the IBM portlet API work. The one sole example that uses the JSR-168 api doesn't show anything apart from the portlet description on the header. The page content is blank. I discovered an exception trace on the server console which goes something like:

[1/12/06 14:37:27:031 IST] 131f43e7 ServletInstan E SRVE0100E: Did not realize init() exception thrown by servlet Struts Standard Blank: javax.servlet.UnavailableException: Exception during portlet initialization: java.lang.NoClassDefFoundError: com/ibm/wps/struts/pluto/base/ErrorInfo
at com.ibm.wps.pe.pc.std.core.PortletServlet$PortletClone.<init>(PortletServlet.java:409)
....
..
.

This is when I did not even touch the code of that example app and just ran it as is. Don't know what this exception is about...tried looking for the unavailable class "com.ibm.wps.struts.pluto.base.ErrorInfo" in the library jars but couldn't find it.

I know there is nothing wrong with the IDE itself (RAD v.6) because I have developed some non-Struts examples which work..

Does anyone know whats up?

Rohit Lal
16 years ago
Stephan:

I finally got the portlet working. I used the code as you had suggested and ran the portlet project itself. I did this on Rational Application Developer since it seems a more integrated tool to develop portlets than WSAD.

Also, in WSAD i couldn't get to publish the portlet project in the in-built test environment and was having to publish it remotely onto the portal server. I suppose the portal toolkit doesn't take care of this? I did not have any problems in using RAD's in-built test environment.

Thanks very much for your help. After this simple hello world portlet, I will try and progress onto to portlets with their full functionalities.

Regards,

Rohit
16 years ago
Thanks Stefan,

Obviously I have still a lot to learn!! I am currently out of town, but will try this as soon as I get back. Thank you very much for your kind assistance, again.

Best regards,

Rohit
16 years ago
Thanks Stefan,

I tried it out, but am now not getting any reponse at all.

When I try the URL giving the portlet name after the web-app name, nothing happens, no error - nothing.
http://192.100.100.80:9086/first/OnePortlet

The "OnePortlet" comes from the <portlet-name> tag in portlet.xml.

I even put in a init(..) method in the portlet with a System.out msg inside, but even that was not invoked. Perhaps there is something wrong with portlet.xml also?

Plus, how will the portlet be registered as a web component in this application? I see there is no mention of it in web.xml?

I appreciate your reponse very much. I know I've asked very beginner level questions, so please do excuse me.

Best regards, Rohit
16 years ago
Hi All,

I have been suffering for the past few days working with WSAD 5.1.2 with the Portal Toolkit option to enable portlet development. I am using Websphere Portal Server 5.1 as my test environment.

I have developed a JSR-168 portlet, but it refuses to work. I don't know what I have missed, since I'm a complete greenhorn. I have the following files in the project:

OnePortlet.java
===============

package com.first.portlet.one;

import java.io.IOException;
import java.io.PrintWriter;

import javax.portlet.ActionRequest;
import javax.portlet.ActionResponse;
import javax.portlet.Portlet;
import javax.portlet.PortletConfig;
import javax.portlet.PortletException;
import javax.portlet.RenderRequest;
import javax.portlet.RenderResponse;
import javax.portlet.GenericPortlet;

public class OnePortlet extends GenericPortlet
{
protected void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException
{
PrintWriter out = response.getWriter();
out.println("Hello World");
}
}

web.xml
=======
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app id="first">
<servlet>
<servlet-name>OnePortlet</servlet-name>
<servlet-class>com.ibm.wps.pe.pc.std.core.PortletServlet</servlet-class>
<init-param>
<param-name>servlet-oid</param-name>
<param-value>OnePortlet</param-value>
</init-param>
<init-param>
<param-name>servlet-class</param-name>
<param-value>com.first.portlet.one.OnePortlet</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>OnePortlet</servlet-name>
<url-pattern>/OnePortlet/*</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
</welcome-file-list>
<taglib id="PortletTLD">
<taglib-uri>http://java.sun.com/portlet</taglib-uri>;
<taglib-location>/WEB-INF/tld/std-portlet.tld</taglib-location>
</taglib>
</web-app>


portlet.xml
==============
<?xml version="1.0" encoding="UTF-8"?>
<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" version="1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd">
<portlet id="Portlet_1">
<description>One Portlet description.</description>
<portlet-name>OnePortlet</portlet-name>
<display-name>One Portlet Display Name</display-name>
<portlet-class>com.first.portlet.one.OnePortlet</portlet-class>
<expiration-cache>-1</expiration-cache>
<supports>
<mime-type>text/html</mime-type>
<portlet-mode>VIEW</portlet-mode>
</supports>
<supported-locale>en</supported-locale>
<resource-bundle>first.nl.FirstPortletResource</resource-bundle>
<portlet-info>
<title>OnePortlet</title>
<keywords>One, Portlet, One Portlet</keywords>
</portlet-info>
</portlet>
</portlet-app>

I get this huge exception trace starting with a message that says "prepare method was not called". Given below is the exception trace. Any ideas on what I'm missing?

[12/23/05 18:58:30:344 IST] 7b9af804 WebGroup I SRVE0180I: [First.war] [/first] [Servlet.LOG]: OnePortlet: init
[12/23/05 18:58:30:844 IST] 7b9af804 ServletInstan E SRVE0100E: Did not realize init() exception thrown by servlet OnePortlet: javax.servlet.ServletException: The prepare method was never called
at com.ibm.wps.pe.pc.std.core.PortletServlet.init(PortletServlet.java:98)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doInit(StrictServletInstance.java:82)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._init(StrictLifecycleServlet.java:147)
at com.ibm.ws.webcontainer.servlet.PreInitializedServletState.init(StrictLifecycleServlet.java:270)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.init(StrictLifecycleServlet.java:113)
at com.ibm.ws.webcontainer.servlet.ServletInstance.init(ServletInstance.java:189)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.addServlet(WebAppServletManager.java:876)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.loadServlet(WebAppServletManager.java:224)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.getServletReference(WebAppServletManager.java:455)
at com.ibm.ws.webcontainer.webapp.WebApp.getServletReference(WebApp.java:652)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.calculateInfo(WebAppRequestDispatcherInfo.java:187)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.<init>(WebAppRequestDispatcherInfo.java:68)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1464)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1423)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)
---- Begin backtrace for Nested Throwables
java.lang.IllegalStateException: The prepare method was never called
at org.apache.pluto.PortletContainerServices.get(PortletContainerServices.java:38)
at org.apache.pluto.services.factory.FactoryManager.getService(FactoryManager.java:42)
at org.apache.pluto.services.factory.FactoryManager.getFactory(FactoryManager.java:37)
at org.apache.pluto.util.ObjectIDAccess.getObjectIDFactory(ObjectIDAccess.java:33)
at org.apache.pluto.util.ObjectIDAccess.createObjectID(ObjectIDAccess.java:28)
at com.ibm.wps.pe.pc.std.core.PortletServlet.init(PortletServlet.java:82)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doInit(StrictServletInstance.java:82)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._init(StrictLifecycleServlet.java:147)
at com.ibm.ws.webcontainer.servlet.PreInitializedServletState.init(StrictLifecycleServlet.java:270)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.init(StrictLifecycleServlet.java:113)
at com.ibm.ws.webcontainer.servlet.ServletInstance.init(ServletInstance.java:189)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.addServlet(WebAppServletManager.java:876)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.loadServlet(WebAppServletManager.java:224)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.getServletReference(WebAppServletManager.java:455)
at com.ibm.ws.webcontainer.webapp.WebApp.getServletReference(WebApp.java:652)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.calculateInfo(WebAppRequestDispatcherInfo.java:187)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.<init>(WebAppRequestDispatcherInfo.java:68)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1464)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1423)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)

[12/23/05 18:58:31:047 IST] 7b9af804 WebGroup E SRVE0020E: [Servlet Error]-[OnePortlet]: Failed to load servlet: java.lang.IllegalStateException: The prepare method was never called
at org.apache.pluto.PortletContainerServices.get(PortletContainerServices.java:38)
at org.apache.pluto.services.factory.FactoryManager.getService(FactoryManager.java:42)
at org.apache.pluto.services.factory.FactoryManager.getFactory(FactoryManager.java:37)
at org.apache.pluto.util.ObjectIDAccess.getObjectIDFactory(ObjectIDAccess.java:33)
at org.apache.pluto.util.ObjectIDAccess.createObjectID(ObjectIDAccess.java:28)
at com.ibm.wps.pe.pc.std.core.PortletServlet.init(PortletServlet.java:82)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doInit(StrictServletInstance.java:82)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._init(StrictLifecycleServlet.java:147)
at com.ibm.ws.webcontainer.servlet.PreInitializedServletState.init(StrictLifecycleServlet.java:270)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.init(StrictLifecycleServlet.java:113)
at com.ibm.ws.webcontainer.servlet.ServletInstance.init(ServletInstance.java:189)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.addServlet(WebAppServletManager.java:876)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.loadServlet(WebAppServletManager.java:224)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.getServletReference(WebAppServletManager.java:455)
at com.ibm.ws.webcontainer.webapp.WebApp.getServletReference(WebApp.java:652)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.calculateInfo(WebAppRequestDispatcherInfo.java:187)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.<init>(WebAppRequestDispatcherInfo.java:68)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1464)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1423)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)

[12/23/05 18:58:31:094 IST] 7b9af804 WebGroup E SRVE0026E: [Servlet Error]-[OnePortlet]: java.lang.IllegalStateException: The prepare method was never called
at org.apache.pluto.PortletContainerServices.get(PortletContainerServices.java:38)
at org.apache.pluto.services.factory.FactoryManager.getService(FactoryManager.java:42)
at org.apache.pluto.services.factory.FactoryManager.getFactory(FactoryManager.java:37)
at org.apache.pluto.util.ObjectIDAccess.getObjectIDFactory(ObjectIDAccess.java:33)
at org.apache.pluto.util.ObjectIDAccess.createObjectID(ObjectIDAccess.java:28)
at com.ibm.wps.pe.pc.std.core.PortletServlet.init(PortletServlet.java:82)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doInit(StrictServletInstance.java:82)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._init(StrictLifecycleServlet.java:147)
at com.ibm.ws.webcontainer.servlet.PreInitializedServletState.init(StrictLifecycleServlet.java:270)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.init(StrictLifecycleServlet.java:113)
at com.ibm.ws.webcontainer.servlet.ServletInstance.init(ServletInstance.java:189)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.addServlet(WebAppServletManager.java:876)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.loadServlet(WebAppServletManager.java:224)
at com.ibm.ws.webcontainer.webapp.WebAppServletManager.getServletReference(WebAppServletManager.java:455)
at com.ibm.ws.webcontainer.webapp.WebApp.getServletReference(WebApp.java:652)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.calculateInfo(WebAppRequestDispatcherInfo.java:187)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcherInfo.<init>(WebAppRequestDispatcherInfo.java:68)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1464)
at com.ibm.ws.webcontainer.webapp.WebApp.getRequestDispatcher(WebApp.java:1423)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)
16 years ago
I have been working on a trial edition of Websphere Portal for Multiplatforms v5.1. I'm using WSAD 5.1.2 (trial edition) along with the Portal Toolkit that enables portal development. I have developed a portlet which I need to deploy on the portal server remotely from WSAD.

The enterprise application containing the portlet is published successfully on the portal server, but the problem comes when the server is starting up. The following error comes before a huge exception trace:

CMPN0069E: Unable to register compensation because a work area partition could not be created. The error was: javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".

The enterprise application containing the portlet seems to be deployed on the server physically, but the server is unable to startup for us to be able to access it.

I get the error in all cases, whether I try to publish and run the portal application on the target server, or I simply start the server, keeping the portal application totally out of the picture.

It seems to me the server is facing some configuration issue. Any idea, people? Did I miss something while installing Websphere Portal? I don't recall seeing anything explicitly being asked about a "Partition Manager" during installation.

The full server log output with the exception trace is given below:

*** Starting the server ***
************ Start Display Current Environment ************
WebSphere Platform 5.1 [BASE 5.1.1.1 cf10435.07] [JDK 1.4.2 cn1420-20040626] [PME 5.1.1 o0429.02] running with process name localhost\localhost\server1 and process id 664
Host Operating System is Windows 2003, version 5.2
Java version = J2RE 1.4.2 IBM Windows 32 build cn1420-20040626 (JIT enabled: jitc), Java Compiler = jitc, Java VM name = Classic VM
was.install.root = C:\WebSphere\AppServer
user.install.root = C:\WebSphere\AppServer
Java Home = C:\WebSphere\AppServer\java\jre
ws.ext.dirs = C:\WebSphere\AppServer/java/lib;C:\WebSphere\AppServer/classes;C:\WebSphere\AppServer/classes;C:\WebSphere\AppServer/lib;C:\WebSphere\AppServer/lib/ext;C:\WebSphere\AppServer/web/help;C:\WebSphere\AppServer/deploytool/itp/plugins/com.ibm.etools.ejbdeploy/runtime
Classpath = C:\WebSphere\AppServer/properties;C:\WebSphere\AppServer/properties;C:\WebSphere\AppServer/lib/bootstrap.jar;C:\WebSphere\AppServer/lib/j2ee.jar;C:\WebSphere\AppServer/lib/lmproxy.jar;C:\WebSphere\AppServer/lib/urlprotocols.jar;C:\Program Files\IBM\IBM Agent Controller\lib\wasToolsCommonV5.jar;C:\Program Files\IBM\IBM Agent Controller\lib\wteServersV5.jar;C:\Program Files\IBM\IBM Agent Controller\lib\logutil.jar;C:\WebSphere\AppServer\properties;C:\WebSphere\AppServer\lib\bootstrap.jar;C:\WebSphere\AppServer\lib\lmproxy.jar
Java Library path = C:\WebSphere\AppServer\java\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\WebSphere\AppServer\bin;C:\Program Files\IBM\IBM Agent Controller\bin;c:\WebSphere\AppServer\WebSphere MQ\Java\lib;C:\WebSphere\SQLLIB\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;c:\WebSphere\AppServer\WebSphere MQ\bin;c:\WebSphere\AppServer\WebSphere MQ\WEMPS\bin
************* End Display Current Environment *************
[12/20/05 17:37:10:328 IST] 30a9fc5a ManagerAdmin I TRAS0017I: The startup trace state is *=all=disabled.
[12/20/05 17:37:11:703 IST] 30a9fc5a AdminInitiali A ADMN0015I: AdminService initialized
[12/20/05 17:37:12:906 IST] 30a9fc5a Configuration A SECJ0215I: Successfully set JAAS login provider configuration class to com.ibm.ws.security.auth.login.Configuration.
[12/20/05 17:37:13:031 IST] 30a9fc5a Parser E SECJ4046E: Duplicate login config name system.WEB_INBOUND. Will over write.
[12/20/05 17:37:13:031 IST] 30a9fc5a Parser E SECJ4046E: Duplicate login config name system.RMI_OUTBOUND. Will over write.
[12/20/05 17:37:13:047 IST] 30a9fc5a Parser E SECJ4046E: Duplicate login config name system.RMI_INBOUND. Will over write.
[12/20/05 17:37:13:047 IST] 30a9fc5a Parser E SECJ4046E: Duplicate login config name system.DEFAULT. Will over write.
[12/20/05 17:37:13:047 IST] 30a9fc5a SecurityDM I SECJ0231I: The Security component's FFDC Diagnostic Module com.ibm.ws.security.core.SecurityDM registered successfully: true.
[12/20/05 17:37:13:250 IST] 30a9fc5a SecurityCompo I SECJ0309I: Java 2 Security is disabled.
[12/20/05 17:37:13:266 IST] 30a9fc5a SecurityCompo I SECJ0212I: WCCM JAAS configuration information successfully pushed to login provider class.
[12/20/05 17:37:13:266 IST] 30a9fc5a SecurityCompo I SECJ0240I: Security service initialization completed successfully
[12/20/05 17:37:13:266 IST] 30a9fc5a JMSRegistrati A MSGS0602I: WebSphere Embedded Messaging Client only has been installed
[12/20/05 17:37:14:562 IST] 30a9fc5a JMSRegistrati A MSGS0601I: WebSphere Embedded Messaging has not been installed
[12/20/05 17:37:15:062 IST] 30a9fc5a AppProfileCom I ACIN0007I: The application profiling service started successfully.
[12/20/05 17:37:15:125 IST] 30a9fc5a CacheServiceI I DYNA0048I: WebSphere Dynamic Cache initialized successfully.
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O com.ibm.ws.exception.RuntimeWarning: CMPN0069E: Unable to register compensation because a work area partition could not be created. The error was: javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
.
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:221)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at java.lang.reflect.Method.invoke(Method.java:391)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O Caused by: javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at javax.naming.InitialContext.lookup(InitialContext.java:361)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O ... 15 more
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O ---- Begin backtrace for nested exception
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at javax.naming.InitialContext.lookup(InitialContext.java:361)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at java.lang.reflect.Method.invoke(Method.java:391)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
[12/20/05 17:37:15:172 IST] 30a9fc5a SystemOut O at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
[12/20/05 17:37:15:172 IST] 30a9fc5a ContainerImpl E WSVR0501E: Error creating component null [class com.ibm.ws.compensation.CompensateComponentImpl]
com.ibm.ws.exception.RuntimeWarning: CMPN0069E: Unable to register compensation because a work area partition could not be created. The error was: javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
.
at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:221)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
Caused by: javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
... 15 more
---- Begin backtrace for nested exception
javax.naming.NameNotFoundException: Name "websphere/WorkAreaPartitionManager" not found in context "services:".
at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)
at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1253)
at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
at com.ibm.ws.compensation.CompensateComponentImpl.start(CompensateComponentImpl.java:137)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)

[12/20/05 17:37:16:672 IST] 30a9fc5a JMXSoapAdapte A ADMC0013I: SOAP connector available at port 8888
[12/20/05 17:37:16:688 IST] 30a9fc5a SecurityCompo I SECJ0243I: Security service started successfully
[12/20/05 17:37:16:688 IST] 30a9fc5a SecurityCompo I SECJ0210I: Security enabled false
[12/20/05 17:37:17:328 IST] 30a9fc5a ApplicationMg A WSVR0200I: Starting application: IBMUTC
[12/20/05 17:37:17:406 IST] 30a9fc5a WebContainer A SRVE0161I: IBM WebSphere Application Server - Web Container. Copyright IBM Corp. 1998-2002
[12/20/05 17:37:17:422 IST] 30a9fc5a WebContainer A SRVE0162I: Servlet Specification Level: 2.3
[12/20/05 17:37:17:422 IST] 30a9fc5a WebContainer A SRVE0163I: Supported JSP Specification Level: 1.2
[12/20/05 17:37:17:484 IST] 30a9fc5a WebContainer A SRVE0169I: Loading Web Module: IBM Universal Test Client.
[12/20/05 17:37:17:828 IST] 30a9fc5a WebGroup I SRVE0180I: [IBM Universal Test Client] [/UTC] [Servlet.LOG]: JSP 1.2 Processor: init
[12/20/05 17:37:17:906 IST] 30a9fc5a WebGroup I SRVE0180I: [IBM Universal Test Client] [/UTC] [Servlet.LOG]: SimpleFileServlet: init
[12/20/05 17:37:17:938 IST] 30a9fc5a ApplicationMg A WSVR0221I: Application started: IBMUTC
[12/20/05 17:37:17:938 IST] 30a9fc5a ApplicationMg A WSVR0200I: Starting application: DefaultEAR
[12/20/05 17:37:18:016 IST] 30a9fc5a WebContainer A SRVE0169I: Loading Web Module: Test.
[12/20/05 17:37:18:047 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: JSP 1.2 Processor: init
[12/20/05 17:37:18:109 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: SimpleFileServlet: init
[12/20/05 17:37:18:109 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: InvokerServlet: init
[12/20/05 17:37:18:125 IST] 30a9fc5a ApplicationMg A WSVR0221I: Application started: DefaultEAR
[12/20/05 17:37:18:141 IST] 30a9fc5a PMECheckServe W PMWC0001W: WebSphere Business Integration Server Foundation functionality is disabled due to missing Integration Server config file: java.io.FileNotFoundException: \\stingray-portal\stingray-portal\config\cells\localhost\nodes\localhost\servers\server1\server-pme.xml (The system cannot find the file specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:129)
at org.eclipse.emf.ecore.resource.impl.URIConverterImpl.createFileInputStream(URIConverterImpl.java:419)
at org.eclipse.emf.ecore.resource.impl.URIConverterImpl.createInputStream(URIConverterImpl.java:385)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:752)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:220)
at com.ibm.websphere.resource.WASResourceSetImpl.getExistingResource(WASResourceSetImpl.java:44)
at com.ibm.websphere.resource.WASResourceSetImpl.createResource(WASResourceSetImpl.java:61)
at com.ibm.ws.runtime.service.ConfigRootImpl.getResource(ConfigRootImpl.java:261)
at com.ibm.ws.wccm.services.pme.PMECheckServerConfigService.start(PMECheckServerConfigService.java:120)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:152)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)

[12/20/05 17:37:18:156 IST] 30a9fc5a HttpTransport A SRVE0171I: Transport http is listening on port 9,086.
[12/20/05 17:37:20:281 IST] 30a9fc5a TraceNLS u No message text associated with key Unable.to.create.server.socket in bundle com.ibm.ejs.resources.seriousMessages
[12/20/05 17:37:20:281 IST] 30a9fc5a SSLServerSock E Unable to create server socket
[12/20/05 17:37:20:297 IST] 30a9fc5a WebContainer E SRVE0146E: Failed to Start Transport on host , port 9443. The most likely cause is that the port is already in use. Please ensure that no other applications are using this port and restart the server. com.ibm.ws.webcontainer.exception.TransportException: Failed to start transport https: java.net.BindException: Address already in use: NET_Bind
at com.ibm.ws.webcontainer.http.HttpTransport.startTransport(HttpTransport.java:148)
at com.ibm.ws.webcontainer.WebContainer.startTransports(WebContainer.java:637)
at com.ibm.ws.runtime.component.WebContainerImpl.startTransports(WebContainerImpl.java:319)
at com.ibm.ws.runtime.component.WebContainerImpl.vetoableChange(WebContainerImpl.java:343)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:313)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:333)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:230)
at com.ibm.ws.runtime.component.ComponentImpl.setState(ComponentImpl.java:107)
at com.ibm.ws.runtime.component.ComponentImpl.setStartState(ComponentImpl.java:144)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:158)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)

[12/20/05 17:37:25:359 IST] 30a9fc5a ApplicationMg A WSVR0217I: Stopping application: DefaultEAR
[12/20/05 17:37:25:359 IST] 30a9fc5a WebContainer A SRVE0170I: Stopping Web Module: Test.
[12/20/05 17:37:25:359 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: InvokerServlet: destroy
[12/20/05 17:37:25:359 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: SimpleFileServlet: destroy
[12/20/05 17:37:25:375 IST] 30a9fc5a WebGroup I SRVE0180I: [Test] [/.Test] [Servlet.LOG]: JSP 1.2 Processor: destroy
[12/20/05 17:37:25:422 IST] 30a9fc5a ApplicationMg A WSVR0220I: Application stopped: DefaultEAR
[12/20/05 17:37:25:422 IST] 30a9fc5a ApplicationMg A WSVR0217I: Stopping application: IBMUTC
[12/20/05 17:37:25:422 IST] 30a9fc5a WebContainer A SRVE0170I: Stopping Web Module: IBM Universal Test Client.
[12/20/05 17:37:25:438 IST] 30a9fc5a WebGroup I SRVE0180I: [IBM Universal Test Client] [/UTC] [Servlet.LOG]: SimpleFileServlet: destroy
[12/20/05 17:37:25:438 IST] 30a9fc5a WebGroup I SRVE0180I: [IBM Universal Test Client] [/UTC] [Servlet.LOG]: JSP 1.2 Processor: destroy
[12/20/05 17:37:25:609 IST] 30a9fc5a ApplicationMg A WSVR0220I: Application stopped: IBMUTC
[12/20/05 17:37:25:609 IST] 30a9fc5a AppProfileCom I ACIN0009I: The application profiling service is stopping.
[12/20/05 17:37:25:641 IST] 30a9fc5a WsServer E WSVR0003E: Server server1 failed to start
com.ibm.ws.exception.RuntimeError
at com.ibm.ws.webcontainer.WebContainer.startTransports(WebContainer.java:648)
at com.ibm.ws.runtime.component.WebContainerImpl.startTransports(WebContainerImpl.java:319)
at com.ibm.ws.runtime.component.WebContainerImpl.vetoableChange(WebContainerImpl.java:343)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:313)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:333)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:230)
at com.ibm.ws.runtime.component.ComponentImpl.setState(ComponentImpl.java:107)
at com.ibm.ws.runtime.component.ComponentImpl.setStartState(ComponentImpl.java:144)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:158)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)
Caused by: com.ibm.ws.webcontainer.exception.TransportException: Failed to start transport https: java.net.BindException: Address already in use: NET_Bind
at com.ibm.ws.webcontainer.http.HttpTransport.startTransport(HttpTransport.java:148)
at com.ibm.ws.webcontainer.WebContainer.startTransports(WebContainer.java:637)
... 20 more
---- Begin backtrace for nested exception
com.ibm.ws.webcontainer.exception.TransportException: Failed to start transport https: java.net.BindException: Address already in use: NET_Bind
at com.ibm.ws.webcontainer.http.HttpTransport.startTransport(HttpTransport.java:148)
at com.ibm.ws.webcontainer.WebContainer.startTransports(WebContainer.java:637)
at com.ibm.ws.runtime.component.WebContainerImpl.startTransports(WebContainerImpl.java:319)
at com.ibm.ws.runtime.component.WebContainerImpl.vetoableChange(WebContainerImpl.java:343)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:313)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:333)
at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:230)
at com.ibm.ws.runtime.component.ComponentImpl.setState(ComponentImpl.java:107)
at com.ibm.ws.runtime.component.ComponentImpl.setStartState(ComponentImpl.java:144)
at com.ibm.ws.runtime.component.ApplicationServerImpl.start(ApplicationServerImpl.java:158)
at com.ibm.ws.runtime.component.ContainerImpl.startComponents(ContainerImpl.java:536)
at com.ibm.ws.runtime.component.ContainerImpl.start(ContainerImpl.java:413)
at com.ibm.ws.runtime.component.ServerImpl.start(ServerImpl.java:243)
at com.ibm.ws.runtime.WsServer.start(WsServer.java:128)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:225)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:189)
at com.ibm.etools.websphere.tools.runner.api.ServerRunnerV5$1.run(ServerRunnerV5.java:97)

[12/20/05 17:37:25:656 IST] 30a9fc5a WsServer E WSVR0009E: Error occurred during startup
16 years ago
Hi All,
I was thinking of adding this as a reply to that great discussion on 'When not to use EJB', but dithered because, well, my problem spans only a miniscule section of that topic. Plus, my query faced the possibility of being lost in the deluge of answers in that discussion.
My problem, rather query, is - When querying the d/b, should I use finder methods from my local entities through my session facade? Should I go through the container at all? Why not use a plain DAO for simple queries? I would again make a distinction here - I totally agree on using finders to get the relevant local object in order to make an update. But for the other stuff where you just have to show information on the client - why go through the container?
Wouldn't it make more sense to handle the DAO access and session facade access through a plain java class designated as a business object? Or some other mechanism (JDO perhaps...?) which doesn't use the container?
Which brings me to yet another query - should I be stingy about using the container?
Till now I've only been met with stares and scandalized looks as if I've questioned the very existence of God. I'm a believer - but I need to know that God is not omnipresent.
Rohit
Hi,
Is your client accessing the server from outside the server's context? If it isn't then no properties need to be provided. But it seems in your case that you are accessing the server from outside it's context. In that case, you would have to provide a second property - Context.PROVIDER_URL which basically specifies an IIOP/Corba based URL from which your client will be able to locate the datasource.
The link provided below will show you examples:
http://publib7b.boulder.ibm.com/wasinfo1/en/info/ae/ae/rnam_example_prop2.html
Regards,
Rohit Lal
Hello,
Well, I would recommend that you do switch over to Prepared Statements instead of trying work-around solutions. Prepared Statements may be expensive to build the first time round, but I feel they add a great deal of flexibility and maintainability to an application if used properly.
Sounds like a caveat? It isn't actually. Not if you have already built yourself a neat little Data Access Object (DAO) class with all the prepared statements initialised on instantiation of this class. Then with appropriate method calls you can pass arguements to call the relevant statement and execute it. All your JDBC code encapsulated in one DAO class.
Makes life a lot simpler.
Hi,
The stack trace though not aailable right now, was basically pointing to the line which had the lookup. "Connection refused" was part of the message in the trace. Howeer, we got the problem- it was the rmi.xml file which forms part of the configuration files for OC4J. It needed the IP, security principal (user name) and credentials (password).
<?xml version = '1.0' standalone = 'yes'?>
<!DOCTYPE rmi-server PUBLIC "Orion RMI-server" "http://xmlns.oracle.com/ias/dtds/rmi-server.dtd">
<rmi-server port="23891">
<!-- A remote server connection example -->
<!-- <server host="the.remote.server.com" username="adminUser" password="123abc" /> -->
<!-- path to the log-file where RMI-events/errors are stored -->
<log>
<file path="log/rmi.log"/>
</log>
</rmi-server>
Hi,
I successfully performed a lookup using the InitialContext from a Java client after setting all the properties to obtain the context for the conatiner in the locally running Oracle JDeveloper IDE.
Following were the properties:
INITIAL_CONTEXT_FACTORY=com.evermind.server.rmi.RMIInitialContextFactory
SECURITY_PRINCIPAL=admin
SECURITY_CREDENTIALS=welcome
PROVIDER_URL=ormi://localhost:23891/current-workspace-app
However, once I ported the application to Oracle 9iAS and changed the PROVIDER_URL to -
PROVIDER_URL=ormi://<server ip>:23791/appname
all jndi lookups fail, whether to call a method on some ejb or to obtain a datasource. My client is a Java client invoked from a batch file. DataSource name in the Application server is given as "DIS" - which translates to "jdbc/DISDS" while performing lookups. Here's the code for the client which tries to get the datasource:
=====================================
Hashtable props = new Hashtable();
props.put(Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
props.put(Context.SECURITY_PRINCIPAL, "admin");
props.put(Context.SECURITY_CREDENTIALS, "welcome");
props.put(Context.PROVIDER_URL, "ormi://192.100.100.239:23791/DISApplication");
Context ctx = new InitialContext(props);
javax.sql.DataSource ds = (javax.sql.DataSource)ctx.lookup("jdbc/DISDS");
=====================================
I get the following exception on the line where the lookup is performed:
java.net.ConnectException: Connection refused.
What am I doing wrong?
Thanks, Rohit