ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Webclient-Servlet

Post new topic  Reply to topic
 Webclient-Servlet « View previous topic :: View next topic » 
Author Message
kotha
PostPosted: Tue Jun 28, 2005 9:28 am    Post subject: Webclient-Servlet Reply with quote

Partisan

Joined: 12 Mar 2005
Posts: 333

I want to modify the webclient servlet to meet the needs of my application.
I have found the below code in web.xml file
<servlet-class>com.ibm.workflow.servlet.client.Main</servlet-class>

I made a search in WAS but not found any!!!.

Where exactly the servlet class and java located in the WAS??
Back to top
View user's profile Send private message
Ratan
PostPosted: Tue Jun 28, 2005 10:08 am    Post subject: Reply with quote

Grand Master

Joined: 18 Jul 2002
Posts: 1245

to customize the WebClient, you have to customize the viewer and command handler depending on your needs.

com.ibm.workflow.servlet.client.Main would be in the fmcojcli.jar and I dont think you have to touch it.
_________________
-Ratan
Back to top
View user's profile Send private message Send e-mail
kotha
PostPosted: Tue Jun 28, 2005 10:25 am    Post subject: Reply with quote

Partisan

Joined: 12 Mar 2005
Posts: 333

Thax Ratan,

The issue is:
I am using web client. When a form submitted, the response is going to a default JSP page saying that your request is submitted and etc....

I assume that whenever form is submitted, it is going to a servlet and after manipulations, the display going to JSP. My concern is to modify the url at response.sendRedirect("something.jsp....") in the servlet [as I am using IIS, I need to mention a asp page. I found help to modify the servlet in other forum to redirect to ASP from servlet.]

I checked the JSP files in forms folder(WAS) but they are for the webclient displya purpose.

the Basic question is: How does the webclient work??. Is webclient use servlet??.
I have no idea how the webclient works.

thx in advance
Back to top
View user's profile Send private message
Ratan
PostPosted: Tue Jun 28, 2005 10:32 am    Post subject: Reply with quote

Grand Master

Joined: 18 Jul 2002
Posts: 1245

Look at the MVC pattern for Web Applications. WF Webclient is implemented using MVC Patter.

I think you need to modify the JSPViewer class to redirect a response.
_________________
-Ratan
Back to top
View user's profile Send private message Send e-mail
kotha
PostPosted: Tue Jun 28, 2005 10:41 am    Post subject: Reply with quote

Partisan

Joined: 12 Mar 2005
Posts: 333

Thank you. I will check JSPViewer.
Back to top
View user's profile Send private message
kotha
PostPosted: Wed Jun 29, 2005 11:21 am    Post subject: Reply with quote

Partisan

Joined: 12 Mar 2005
Posts: 333

I have got the solution. The page that displays after a new process instance created and started has to be modified as we dont have the access to the servlet.

UseRedirect should be set to true and the SuccessLocation can be any page on any server.

Code to be included:

Code:
<input type="hidden" name="UseRedirect" value="true">
   <input type="hidden" name="SuccessLocation" value="Anypage.asp">
Back to top
View user's profile Send private message
kotha
PostPosted: Thu Jun 30, 2005 10:16 am    Post subject: Reply with quote

Partisan

Joined: 12 Mar 2005
Posts: 333

I am trying to get the input data structure member values into a Jsp page.
the code is given below:

Code:
<%@ page language="java" info="'Your request is submitted' JSP" %>
<%@ page errorPage="/forms/ViewError.jsp" %>
<%@ page import="java.util.*,com.ibm.workflow.api.*,com.ibm.workflow.api.ProcessInstancePackage.*,
com.ibm.workflow.api.ItemPackage.*,com.ibm.workflow.servlet.client.*" %>

<jsp:useBean id="context" scope="request"
             type="com.ibm.workflow.servlet.client.RequestContext"/>
<html>
<%
  ReadOnlyContainer inData = context.getContainer();
  WorkItem workItem = context.getWorkItem();
  context.getprocessInstanceName();
String Jobname = context.getMemberValue(inData, "_PROCESS", "&lt;notset&gt;");
  String user = context.getUserID();
   //String serverid = context.getMemberValue(inData, "serverid", "&lt;notset&gt;");
  %>
<head>
  <title>Your request has been submitted</title>
  <link rel="stylesheet" href="../jdrcss.css">
</head>

<body>
 
    <input type="text" name="instance" value="<%=context.getInstance().name()%>">
   <input type="text" name="starter" value="<%=user%>">
   <input type="text" name="Jobname" value="<%=Jobname%>">
   



</body>
</html>



Instance, starter values are fine but when I try to get Jobname, input data structure member, I am getting null pointer exception.
How can I get the data structure elements into a JSP page??
Back to top
View user's profile Send private message
jmac
PostPosted: Thu Jun 30, 2005 11:46 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Jun 2001
Posts: 3081
Location: EmeriCon, LLC

It seems to me that the most likely cause for the null pointer would be if inData is null. Now I am not sure why that would be the case, but since you have the workitem anyway, why not try getting the input container with
Code:
workItem.inContainer()

_________________
John McDonald
RETIRED
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Webclient-Servlet
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.