Session tracking in java client app...*not jsp or servlets*

Does anyone know of a way to keep a property accessible throughout a user session in a Java app? I'm writing a Java native client app with Apache Axis to access remote .NET services (web services). The service issues a session ticket upon login to implement security...this ticket needs to be accessible to all objects in the client app. In addition, this ticket needs to be "renewed" every 10 minutes or so.
Any ideas on how to keep this ticket througout the session? And on how to update/renew every 10 minutes?
ANY help would be appreciated Still relatively new to java...

Hello.
I use the following scenario in my project.
User login to the web application then servlet keeps user data (IP-address, login name, etc) and creates a user ticket with the data. User ticket looks like a XML-element. After that I store the ticket to the Xindice DB.
http://xml.apache.org/xindice/
Xindice client API provides the useful methods for the ticket handling (read, update, delete).

Similar Messages

  • Error: "Mobile java client attributes not maintained" while activating DO

    Hi All,
    i got error while activating the Data Object: "Mobile java client attributes not maintained".
    how to resolve this error, and why this error is coming?
    I am migrating the MI 2.5 application into the MI 7.1 application.In new MI 7.1 application some synbo's are imported using the text file and some new data objects are created. Imported synbo's are activated successfully, but newly created objects are not activated because of the above error.
    Can we solve above error or is there any restriction that in Migration project ( project with backward compatibility ) we can't create new Data objects?
    Thanks & Regards
    Siva Sankar Nulaka.

    Hi Siva,
    Please refer to following document for the solution.
    [http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/e0036580-ab90-2c10-b7a4-f71ba4f43096&overridelayout=true|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/e0036580-ab90-2c10-b7a4-f71ba4f43096&overridelayout=true]
    It should solve your problem.
    Thanks & Regards,
    Abhijit

  • SSLException : untrusted server cert chain in java client, but not getting that with weblogic.

    Hi,
    I am bit confused about what i am seeing,
    a. i used java client to talk to talk to server, got "untrusted server cert chain"
    , ressolved the exceptio by adding certificate to cacerts file.
    b. tried to connect to server using another weblogic server and not getting "untrusted
    server cert chain", even when the certificates are not installed.
    i dont know why it is throwning the SSLException in (a) and not in (b).
    thanks,
    Nirmala

    Stand alone client takes its trusted certificate from the JDK cacerts keystore
    by default.
    SSL client running on server uses server trust configuration. By default the server
    is configured to trust the CAs with certificates in DemoTrust.jks keystore and
    the JDK cacerts keystore.
    Pavel.
    "Nirmala" <[email protected]> wrote:
    >
    Hi,
    I am bit confused about what i am seeing,
    a. i used java client to talk to talk to server, got "untrusted server
    cert chain"
    , ressolved the exceptio by adding certificate to cacerts file.
    b. tried to connect to server using another weblogic server and not getting
    "untrusted
    server cert chain", even when the certificates are not installed.
    i dont know why it is throwning the SSLException in (a) and not in (b).
    thanks,
    Nirmala

  • Recording a thick java client app

    Can eTester record a thick java client application? I've tried using proxy but that doesn't appear to work.

    James
    eTester can record thick client app HTTP requests, you should use:
    A external proxy recorder:
    - Options -> Current Script -> Recording -> Proxy and select record navigations in a external application.
    - Remove the ;application/* from the exclude statement
    - Set the proxy of the thick Java app to point to, localhost on port 7777
    If the thick java app is a Java Applet you will need to set the JVM to point to the porxy at locahost 7777 to do so:
    - Start -> Control Panel -> Double click on Java -> under the general tab select network settings, select use proxy server and enter the proxy settings.
    Happy recording !!!!
    Alex
    Edited by: aamat on Dec 10, 2008 9:42 AM
    Edited by: aamat on Dec 10, 2008 9:43 AM

  • Java GUI apps not working

    All my Java apps are not rendering their GUI properly anymore. It seems to affect those that are using a Carbon-ized UI. I'm guessing this means all Swing apps?
    Regardless I'm trying to figure out a way to fix this without re-installing the OS...
    Any tips?
    thanks in advance.
    -j

    Have you tried deleting the Java caches? Close all your Java applications first. You'll find some in <user>:Library:Caches:Java Applets. While you're there you can also clean up anything else in the Caches folder that might be related - it's not a problem to remove anything in here, they'll just get recreated and may cause the related application to start up a bit slower next time.
    There should also be one or more 'Plugin Settings' files in the Applications:Utilities:Java (note: I'm on 10.3.9 and this may be different for you - I have two: one for 1.3.1 and one for 1.4.2). Launch them and use whatever features they have for cleaning up unwanted caches/mess, but I think they just remove the cache files I mentioned in the first paragraph.

  • Retain session in java client , which invokes a dotnet webservice

    Hello Forum,
    I am invoking a dotnet webservice using a java client. But I am not able to maintain session in this java client. I googled this, I got many links for the above. But none of the solution was using pure sun api's. My need is to do the same only using sun api's. Please guide. Any help will be appreciated.
    Best Regards,
    Tejal Khatri

    Apache HttpClient can do that.

  • Java client for OSB service

    Hi All,
    We have to talk to OSB11g proxy service which is created as Any Soap service (url: http://myosb.firmname.com:7001/osb-ws)
    I have java client applications which need to consume this proxy service built on top of OSB by providing the necessary inputs.
    Typically we get wsdl url's and then we use Jdeveloper to create web service client proxies to generate client side web service artifacts and call the web service.
    But I am confused here as to how can I get a handle to the OSB service from a java client. The OSB developers on the project tell me they don't have and cannot provide a WSDL based URL.
    What are the general practices for consuming OSB proxy service from java client apps. Google search result did not yield much help.
    Please let me know your thoughts.
    Regards,

    Hi Anuj,
    Thanks for reply. As u guys mentioned that about the URL I have rechecked the URL and realized the port number which I was using that was Admin Server Port while environment contains two servers Admin and Managed both. I have change the Port Number from Admin to Managed now its hitting the Service but now another problem I start facing that I need to pass a big XML as input request to that OSB Proxy Service. I have two different code where I am attaching the input request in two different ways but none of them is passing that request to URL and in both cases I am getting default response from URL.
    Here is the Code, Code1 through Core Java:
    ===============================================================================================
    package retriggerpsftorder;
    import java.io.BufferedReader;
    import java.io.InputStreamReader;
    import java.io.OutputStreamWriter;
    import java.net.URL;
    import java.net.URLConnection;
    import java.net.URLEncoder;
    public class MyTest {
    public MyTest() {
    System.out.println("Constructor executing");
    System.out.println("JAVA Version : " + System.getProperty("JAVA.VERSION"));
    public static void main(String arga[]) {
    try {
    // Construct data
    String data = URLEncoder.encode("key1", "UTF-8") + "=" + URLEncoder.encode("<migrateOrder>\n" +
    " <migrateOrderId>51c797d61dd211b2818a</migrateOrderId>\n" +
    " <createCustomer>false</createCustomer>\n" +
    " <createBillingAccount>false</createBillingAccount>\n" +
    " <Customer>\n" +
    " <ID>\n" +
    " </PIN>\n" +
    "     </customerAccountNumber\"></customerAccountNumber\">\n" +
    " </externalIdentifier>\n" +
    " </ID>\n" +
    " <creditClass>W</creditClass>\n" +
    " </Customer>\n" +
    " <Account>\n" +
    " <name>Gurwinder Singh</name>\n" +
    " <ID>\n" +
    " <PIN>1987</PIN>\n" +
    "     <billingAccountNumber>695909361</billingAccountNumber>\n" +
    " </ID>\n" +
    " </Account>\n" +
    " <CustomerOrder>\n" +
    " <customerOrderPartyReference>\n" +
    " <MSISDN>61425265789</MSISDN>\n" +
    " </customerOrderPartyReference>\n" +
    " <orderSource>\n" +
    " <templateName>AUP1057_AU10357_24_DATA_0113</templateName>\n" +
    " </orderSource>\n" +
    " <typeCode>Connect</typeCode>\n" +
    " <futureSubmitDate>2011-02-28</futureSubmitDate>\n" +
    " <cancelOpenOrdersIndicator>false</cancelOpenOrdersIndicator>\n" +
    " <lineItem actionCode=\"Add\" priorityRanking=\"1\">\n" +
    " <product ID=\"AUX221\" type=\"SAMID\" attributeCount=\"19\">\n" +
    " <attribute>\n" +
    " <name>Accept Code</name>\n" +
    " <value>Accept 5</value>\n" +
    " </attribute>\n" +
    " </product>\n" +
    " </lineItem>\n" +
    " <lineItem actionCode=\"Add\" priorityRanking=\"2\">\n" +
    " <product ID=\"OFF0018\" type=\"SAMID\" attributeCount=\"1\">\n" +
    " <attribute>\n" +
    " <name>Period Override</name>\n" +
    " <value>24</value>\n" +
    " </attribute>\n" +
    " </product>\n" +
    " </lineItem>\n" +
    " <lineItem actionCode=\"Allocate\" priorityRanking=\"3\">\n" +
    " <equipment ID=\"012645002053476\" type=\"Handset\" />\n" +
    " </lineItem>\n" +
    " <lineItem actionCode=\"Allocate\" priorityRanking=\"4\">\n" +
    " <resource ID=\"89610300000905636996\" type=\"SIM\" />\n" +
    " </lineItem>\n" +
    " <externalOrderReference>\n" +
    " <serviceID>75055433</serviceID>\n" +
    " <customerID>921092224696621123154029260421</customerID>\n" +
    " <serviceStartDate>2009-02-10</serviceStartDate>\n" +
    " <serviceRatePlan>X3Cap $29 24m($29min-35cFF)</serviceRatePlan>\n" +
    " <agreementNumber>VHU0029215</agreementNumber>\n" +
    " <accountNumber>3382437469</accountNumber>\n" +
    " <migrationType>Loyalty Handset Upgrade Acq</migrationType>\n" +
    " <receiveMarketingInfoOverrideIndicator>false</receiveMarketingInfoOverrideIndicator>\n" +
    " </externalOrderReference>\n" +
    " <orderSalesReference>\n" +
    " <dealerReferenceID>D3641</dealerReferenceID>\n" +
    " <trailingCommissionRatePlan>MUPR9</trailingCommissionRatePlan>\n" +
    " <trailingCommisionDealerReference>D3734</trailingCommisionDealerReference>\n" +
    " </orderSalesReference>\n" +
    " </CustomerOrder>\n" +
    " <ContactManagementActivity>\n" +
    " <activityCategory>Proof of Purchase - Mig from 3</activityCategory>\n" +
    " <activityType>Migration from 3</activityType>\n" +
    " <activityDescription>Proof of Purchase Information</activityDescription>\n" +
    " <activityComment>MSISDN: 0425265789354610026170561</activityComment>\n" +
    " </ContactManagementActivity>\n" +
    "</migrateOrder>\n", "UTF-8");
    //data += "&" + URLEncoder.encode("key2", "UTF-8") + "=" + URLEncoder.encode("value2", "UTF-8");
    System.out.println("Data going for Request : "+data);
    // Send data
    URL url = new URL("http://172.22.161.101:8017/app/mig3/migrate/MigrateOrder");
    URLConnection conn = url.openConnection();
    conn.setDoOutput(true);
    OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
    wr.write(data);
    wr.flush();
    // Get the response
    BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
    int i=0;
    while ((line = rd.readLine()) != null) {
    System.out.println("Values of Line : "+ i + " : "+ line);// Process line...
    i++;
    wr.close();
    rd.close();
    } catch (Exception e) {
    =========================================
    Code 1 Response
    Values of Line : 0 : <?xml version="1.0" encoding="UTF-8"?>
    Values of Line : 1 : <migrateOrderReply><statusCode>Failed</statusCode><errorReturn><errorCode>CORE_SYS_GENERIC</errorCode><errorMessage>Unexpected System exception</errorMessage></errorReturn></migrateOrderReply>
    Process exited with exit code 0.
    Note: The above response message is the default response message, even if u not pass any input parameter then also the above message will come.
    ==========================================================================================================
    Code 2 : Using Servlet
    package retriggerpsftorder;
    import java.io.IOException;
    import java.io.PrintWriter;
    import javax.servlet.Servlet;
    import javax.servlet.ServletConfig;
    import javax.servlet.ServletException;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import org.apache.http.client.HttpClient;
    import org.apache.commons.httpclient.HttpConnection;
    import org.apache.commons.httpclient.HttpState;
    import org.apache.commons.httpclient.NameValuePair;
    import org.apache.commons.httpclient.URI;
    import org.apache.commons.httpclient.methods.PostMethod;
    import org.apache.commons.httpclient.methods.RequestEntity;
    import org.apache.http.client.HttpClient;
    public class GIFTProcess extends HttpServlet implements Servlet {
    private static final String CONTENT_TYPE =
    "text/html; charset=windows-1252";
    public void init(ServletConfig config) throws ServletException {
    super.init(config);
    public void doGet(HttpServletRequest req,
    HttpServletResponse resp) throws ServletException,
    IOException {
    resp.setContentType(CONTENT_TYPE);
    PrintWriter out = resp.getWriter();
    try {
    NameValuePair nvpRtn =
    new NameValuePair("body", "<migrateOrder>\n" +
    " <migrateOrderId>51c797d61dd211b2818a</migrateOrderId>\n" +
    " <createCustomer>false</createCustomer>\n" +
    " <createBillingAccount>false</createBillingAccount>\n" +
    " <Customer>\n" + " <ID>\n" +
    " </PIN>\n" +
    "     </customerAccountNumber\"></customerAccountNumber\">\n" +
    " </externalIdentifier>\n" +
    " </ID>\n" +
    " <creditClass>W</creditClass>\n" +
    " </Customer>\n" + " <Account>\n" +
    " <name>Gurwinder Singh</name>\n" +
    " <ID>\n" + " <PIN>1987</PIN>\n" +
    "     <billingAccountNumber>695909361</billingAccountNumber>\n" +
    " </ID>\n" + " </Account>\n" +
    " <CustomerOrder>\n" +
    " <customerOrderPartyReference>\n" +
    " <MSISDN>61425265789</MSISDN>\n" +
    " </customerOrderPartyReference>\n" +
    " <orderSource>\n" +
    " <templateName>AUP1057_AU10357_24_DATA_0113</templateName>\n" +
    " </orderSource>\n" +
    " <typeCode>Connect</typeCode>\n" +
    " <futureSubmitDate>2011-02-28</futureSubmitDate>\n" +
    " <cancelOpenOrdersIndicator>false</cancelOpenOrdersIndicator>\n" +
    " <lineItem actionCode=\"Add\" priorityRanking=\"1\">\n" +
    " <product ID=\"AUX221\" type=\"SAMID\" attributeCount=\"19\">\n" +
    " <attribute>\n" +
    " <name>Accept Code</name>\n" +
    " <value>Accept 5</value>\n" +
    " </attribute>\n" +
    " </product>\n" + " </lineItem>\n" +
    " <lineItem actionCode=\"Add\" priorityRanking=\"2\">\n" +
    " <product ID=\"OFF0018\" type=\"SAMID\" attributeCount=\"1\">\n" +
    " <attribute>\n" +
    " <name>Period Override</name>\n" +
    " <value>24</value>\n" +
    " </attribute>\n" +
    " </product>\n" + " </lineItem>\n" +
    " <lineItem actionCode=\"Allocate\" priorityRanking=\"3\">\n" +
    " <equipment ID=\"012645002053476\" type=\"Handset\" />\n" +
    " </lineItem>\n" +
    " <lineItem actionCode=\"Allocate\" priorityRanking=\"4\">\n" +
    " <resource ID=\"89610300000905636996\" type=\"SIM\" />\n" +
    " </lineItem>\n" +
    " <externalOrderReference>\n" +
    " <serviceID>75055433</serviceID>\n" +
    " <customerID>921092224696621123154029260421</customerID>\n" +
    " <serviceStartDate>2009-02-10</serviceStartDate>\n" +
    " <serviceRatePlan>X3Cap $29 24m($29min-35cFF)</serviceRatePlan>\n" +
    " <agreementNumber>VHU0029215</agreementNumber>\n" +
    " <accountNumber>3382437469</accountNumber>\n" +
    " <migrationType>Loyalty Handset Upgrade Acq</migrationType>\n" +
    " <receiveMarketingInfoOverrideIndicator>false</receiveMarketingInfoOverrideIndicator>\n" +
    " </externalOrderReference>\n" +
    " <orderSalesReference>\n" +
    " <dealerReferenceID>D3641</dealerReferenceID>\n" +
    " <trailingCommissionRatePlan>MUPR9</trailingCommissionRatePlan>\n" +
    " <trailingCommisionDealerReference>D3734</trailingCommisionDealerReference>\n" +
    " </orderSalesReference>\n" +
    " </CustomerOrder>\n" +
    " <ContactManagementActivity>\n" +
    " <activityCategory>Proof of Purchase - Mig from 3</activityCategory>\n" +
    " <activityType>Migration from 3</activityType>\n" +
    " <activityDescription>Proof of Purchase Information</activityDescription>\n" +
    " <activityComment>MSISDN: 0425265789354610026170561</activityComment>\n" +
    " </ContactManagementActivity>\n" +
    "</migrateOrder>\n");
    NameValuePair[] nvpout = { nvpRtn };
    HttpConnection httpConn = new HttpConnection("172.22.161.101", 8017);
    System.out.println("httpConn : " + httpConn.getHost() + " getPost: " + httpConn.getPort());
    httpConn.open();
    System.out.println("Is Connection Open? --> " + httpConn.isOpen());
    PostMethod postMethod = new PostMethod();
    postMethod.setPath("http://172.22.161.101:8017/app/mig3/migrate/MigrateOrder");
    System.out.println("postMethod.getPath() : " + postMethod.getPath());
    //postMethod.setQueryString("http://172.22.161.101:8017/app/mig3/migrate/MigrateOrder");
    //System.out.println("getQueryString : " + postMethod.getQueryString());
    //System.out.println("postMethod.getParams() : " + postMethod.getParams());
    postMethod.setRequestBody(nvpout);
    System.out.println("validate--> " + postMethod.validate());
    postMethod.execute(new HttpState(), httpConn);
    System.out.println("isRequestSent --> " + postMethod.isRequestSent());
    System.out.println("statusLine--> " + postMethod.getStatusLine());
    String serviceResponse = postMethod.getResponseBodyAsString();
    System.out.println("Response from Call : " + serviceResponse);
    } catch (Exception e) {
    out.println("Error Occured during the process.");
    e.printStackTrace();
    ==========================================================================================
    Code 2 Response -----
    C:\Oracle\Middleware\SOASuite101351\jdk\bin\javaw.exe -jar C:\jdevstudio10135\j2ee\home\admin.jar ormi://10.161.1.169:23891 oc4jadmin **** -updateConfig
    11/03/02 15:30:19 WARNING: Shared-library oracle.expression-evaluator:10.1.3.1 is closing, but is imported by adf.oracle.domain:10.1.3.1, adf.generic.domain:10.1.3.1.
    2/03/2011 15:30:19 com.oracle.corba.ee.impl.orb.ORBServerExtensionProviderImpl preInitApplicationServer
    WARNING: ORB ignoring configuration changes. Restart OC4J to apply new ORB configuration.
    Ready message received from Oc4jNotifier.
    Embedded OC4J startup time: 7765 ms.
    Target URL -- http://10.161.1.169:8988/JAVAProject-RetriggerPSFTOrder-context-root/giftprocess
    ERROR: Unable to connect to JQS service: connection refused
    11/03/02 15:30:22 httpConn : 172.22.161.101 getPost: 8017
    11/03/02 15:30:22 Is Connection Open? --> true
    11/03/02 15:30:22 postMethod.getPath() : http://172.22.161.101:8017/app/mig3/migrate/MigrateOrder
    11/03/02 15:30:22 validate--> true
    11/03/02 15:30:22 isRequestSent --> true
    11/03/02 15:30:22 statusLine--> HTTP/1.1 200 OK
    2/03/2011 15:30:22 org.apache.commons.httpclient.HttpConnection releaseConnection
    WARNING: HttpConnectionManager is null. Connection cannot be released.
    11/03/02 15:30:22 Response from Call : <?xml version="1.0" encoding="UTF-8"?>
    <migrateOrderReply><statusCode>Failed</statusCode><errorReturn><errorCode>CORE_SYS_GENERIC</errorCode><errorMessage>Unexpected System exception</errorMessage></errorReturn></migrateOrderReply>
    ==================================================================================
    If u find any thing wrong then please let me know.
    Any reply is highly appreciated.
    Thanks Manish

  • How to use Http test Client  for Java Client Proxy Scenario

    Hi,
    I build a scenario using Java Client Proxy where JSP as my FrontHand.
    Can I know that whether i can use Http Test Client in place of JSP for sending data and getting response back. If yes than how can i implement this ?
    Regards,
    Abhi

    Hi,
    with Http Test Client you post your messages
    directly to the Integration Engine (not using adapter framework)
    so you can use Http Test Client to simulate any message
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Is it posssible to lunch one application from the client system using JSP

    Is it possible to Lunch one application from the client system using JSP or Servlet .If it is possible then how can we do that ?
    Thanks in advance
    Sil

    If its a java application - yes. You can use jnlp and web start.
    ram.

  • Integrationevent wsdlLocation java client

    Hi All,
    I've read the webservice on demand guide but, I don't have a clue how to do this with the integrationevent webservice. I was able to connect to the pod and get the session id with java (client generated with jdeveloper) but now i struggle how to get the sessionid into the proxy to call getEvents. I did this before with .Net and it was no problem there was always a method setUrl(). This is what i have so far but...
    1. is this location a valid wsdl location vor Integrationevent.wsdl used for the call? I
    https://secure-ausomxefa.crmondemand.com/Services/Integration?wsdl
    2. This is the java call:
    //here is the session created and jsessionid is retrieved
    Session sesobj=new Session();
    integrationEventWS = new IntegrationEventWS(); //this is the call that throws the error mentiond down below
    Default_Binding_IntegrationEventWS default_Binding_IntegrationEventWS = integrationEventWS.getDefault();...
    3. and this is the IntegrationEventWS class with the wsdllocation:
    public class IntegrationEventWS
    extends Service
    private static URL wsdlLocationURL;
    private static Logger logger;
    static
    try
    logger = Logger.getLogger("crmondemand.ws.integrationevent.IntegrationEventWS");
    URL baseUrl = IntegrationEventWS.class.getResource(".");
    if (baseUrl == null)
    wsdlLocationURL =
    IntegrationEventWS.class.getResource("https://secure-ausomxefa.crmondemand.com/Services/Integration?wsdl");
    if (wsdlLocationURL == null)
    baseUrl = new File(".").toURL();
    wsdlLocationURL = new URL(baseUrl, "https://secure-ausomxefa.crmondemand.com/Services/Integration?wsdl");
    else
    if (!baseUrl.getPath().endsWith("/")) {
    baseUrl = new URL(baseUrl, baseUrl.getPath() + "/");
    wsdlLocationURL = new URL(baseUrl, "https://secure-ausomxefa.crmondemand.com/Services/Integration?wsdl");
    catch (MalformedURLException e)
    logger.log(Level.ALL,
    "Failed to create wsdlLocationURL using https://secure-ausomxefa.crmondemand.com/Services/Integration?wsdl",
    e);
    public IntegrationEventWS()
    super(wsdlLocationURL,
    new QName("urn:crmondemand/ws/integrationevent/",
    "IntegrationEventWS"));
    public IntegrationEventWS(URL wsdlLocation, QName serviceName)
    super(wsdlLocation, serviceName);
    @WebEndpoint(name="Default")
    public crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS getDefault()
    return (crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS) super.getPort(new QName("urn:crmondemand/ws/integrationevent/",
    "Default"),
    crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS.class);
    @WebEndpoint(name="Default")
    public crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS getDefault(WebServiceFeature... features)
    return (crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS) super.getPort(new QName("urn:crmondemand/ws/integrationevent/",
    "Default"),
    crmondemand.ws.integrationevent.Default_Binding_IntegrationEventWS.class,
    features);
    I'm always getting this error on calling the default constructor of IntegrationEventWS
    Exception breakpoint occurred at line 641 of URLClassPath.java.
    java.io.FileNotFoundException: \ade\aime_xdk_532664\oracle\xdk\lib\xmlparserv2.jar
    Process exited with exit code 0.
    I tried the process with Opportunity WS v2 and it's the same issue... what is wrong with the call??? and where is the sessionid put in?
    Thanks...
    SL

    Hi All,
    finally it did work out with axis to generate the client, but please Oracle do something with your webservices, it can't be so difficult to load a simple webservice into the IDE. The Integrationevent ws documentation isn't really clear and the manual work that has to be done for leveraging the service isn't state of the art at all!
    Regards
    SL

  • Minimal requirements for remote client app to call a EJB 3 session bean

    I'm just starting to get into EJBs, trying to learn the EJB 3 APIs. I kind of understand the setup on the server side to create a session bean. What I don't understand is what I would have to deploy for each of the remote client app (Swing-based GUI or something like that) installations. Of course, the client app code would have to be deployed to each client desktop, but what stuff related to the session bean? Just the session bean interface class?
    For ease of discussion, let's say my bean is CalculatorBean, having two interfaces, CalculatorRemoteIface and CalculatorLocalIface. Let's also say my client app, CalculatorUI, is a simple Swing-based GUI that grabs a reference to a CalculatorBean.
    Other than just the Swing-based classes and the JRE, what JARs/classes will I want to deploy to each desktop?
    (Please assume the latest Sun Java System App Server 9 and Java EE 5, if you are familiar with them.)

    Personally- I would deploy your backend
    in EJB 3.0, but then expose it as a web service. It
    is MUCH easier for your clients to connect to a web
    service (and mantain that code), then to have them
    connect via RMI/JNDI.Oh, I would say it's quite the opposite. RMI/JNDI is MUCH easier from a client point of view than web services. To make web services work easy from the client side you have to generate code and the tools that generate code from a web services wsdl file doesn't do a great job today. But that was not the question. But take some time reading this article about webservices...it's quite funny and spot on: http://wanderingbarque.com/nonintersecting/2006/11/15/the-s-stands-for-simple
    Now to your question, yes you will need the remote interface on the client side.
    /klejs

  • Can we use an overloaded constructor of a Java Bean with Session Tracking

    Hi Friends,
    If any one can solve my query.... It would be helpful.
    Query:
    I have a Java Bean with an overloaded constructor in it. I want to use the overloaded constructor in my JSP.
    1. One way of doing that is to use it directly in the "Scriptlets" (<% %>). But then I am not sure of the way to do session tracking. I think I can use the implicit objects like "session", "request" etc. but not sure of the approach or of the implementation method.
    2. Another way is through the directive <jsp: useBean>. But I cannot call an overloaded constructor with <jsp: useBean>. The only alternative way is to use the directive <jsp: useBean> where I have to write getter and setter methods in the Java Bean and use the <jsp: setProperty> and <jsp: getProperty> standard actions. Then with this approach I cannot use the overloaded constructor.
    Can any one suggest me the best approach to solve this problem ?
    Thanks and Regards,
    Gaive.

    My first reaction is that you can refactor your overloaded constructor into an init(arguments...) method. Instead of overloaded constructor, you can call that init method. This is the ideal solution if possible.
    As to the two choices you listed:
    1. This is OK, I believe. You can use scriplet to define the bean and put it into session scope of the pageContext. I am not sure exactly what you meant by session tracking; whatever you meant, it should be doable using HttpSessionAttributeListener and/or HttpSessionBindingListener.
    2. Agreed. There is no way that <jsp:useBean> can call a constructor that has non-empty arguments.
    Please tell me how it works for you.

  • Creating a simple java client for a session EJB local interface

    Hi all
    Is it possible to create a simple java client for a session ejb local interface with JDeveloper.
    The problem is that it creates a test client for a remote interface only...
    i.e.
    MySessionEJB sessionEJB = context.lookup("MySessionEJB")
    and once i try to adjust it manually for the local interface...
    MySessionEJBLocal sessionEJB = (MySessionEJBLocal) context.lookup("MySessionEJBLocal") (MySessionEJBLocal - is the name of my local interface)
    it generates the exception:
    javax.naming.NotFoundException: SessionEJBLocal not found
    at...........................(RMIClientContext.java:52)
    There is still no problem with accessing the local interface object from the jsf project where i've added <ejb-local-ref> tag into the web.xml file.
    but i need the possibility of testing the simple java client for the local interface to test business methods wich should return objects without indirect properties
    Thanks in advance.
    Alex.

    Pedja thanks for reply.
    I still dont understand what is wrong with my example.
    The first peace of the code i wrote (getting the reference to the remote interface object) works pretty well, and even more it is produced automatically by JDeveloper, so why we cant get a reference to the local interface object the same way?
    Certanly we should use the local interface for getting access to the resource functioning under the same local jvm and i think it doesnt metter wich app server we really use wls or oas or others
    Thanks. Alex.

  • What role can ejb Session Beans  play  jsp session tracking

     

              I am also looking for a way to use JSP as ejb client with WLS5.1. i would appreciate any help.
              -Girish
              Prasad Peddada <[email protected]> wrote:
              >David,
              >     The beans which are refered in jsp specs are java beans and not EJB.
              >
              >Prasad
              >
              >David Levy wrote:
              >>
              >> Hello,
              >>
              >> We are using Jsp/Servlets which will hold session state and subsequently
              >> call ejb Session Beans for transaction/persistence coordination . We are
              >> not sure if we are using the correct techniques to control object memory.
              >>
              >> Summary of what we have:
              >>
              >> A jsp with the "useBean" directive:
              >> <jsp:useBean id="MySession" class="com....MySession"
              >> scope="session"></jsp:useBean>
              >>
              >> The class MySession holds other classes ( all serializable).
              >> The class MySession is NOT an ejb Session Bean
              >>
              >> Questions:
              >> We are considering making class MySession an ejb Session Bean so (via it's
              >> passivate/activate feature) we can control instances in memory as more web
              >> clients start the session from the jsp page. I.E. all web clients will have
              >> their own HttpSession instance which holds on to an ejb Session Bean object
              >> "MySession"( or a passivated representation of it)
              >>
              >> 1) Is this a sufficient approach or will there be other memory concerns?
              >> I.E. What about all the HttpSession objects out there? Do they need to be
              >> passivated as well?
              >>
              >> 2) If its a good idea to passivate the HttpSessions as well, then what
              >> mechanism should be used ( servlet session persistence)? Also, if we are
              >> passivating the HttpSession (which holds on to the MySession object graph)
              >> , then why bother with the SessionBean for passivation
              >>
              >> 3) Currently, we only have a single instance of a servlet handling all
              >> requests. Will multiple instances buy us anything?
              >>
              >> 4) How does clustering relate to this topic?
              >>
              >> 5) Can we change the "jsp:useBean" directive so MySession is an ejb Session
              >> Bean or do we have to do the "home.create()" within a jsp script?
              >>
              >> thanks,
              >> dave
              

  • Unable to get 'InitialContext' using Java Client in Oracle App 10.0.2.0

    Scenario & Problem Description: Unable to get 'Initial Context' using Simple Java Client in Oracle Application Server 10.0.2.0
    I'm having an issue while I try to initialize the Initial Context for an EJB lookup from a simple Java Client [local lookup], but the same code snippet works fine when I try from Servlet. I have enclosed the Exception Stack Trace and the Code Snippet for your reference.
    1. .NET Client ---> Servlet --> LookupUtility --> EJB --> DB - Issue
    2. .NET Client ---> Servlet --> EJB --> DB - Works
    Exception: java.lang.InstantiationException: Error communicating with server: Lookup error: javax.naming.AuthenticationException: Invalid username/password for Config (guest); nested exception is: nested exception is: Exception in InitialContext: javax.naming.NamingException: Lookup error: javax.naming.AuthenticationException: Invalid username/password for Config (guest) at com.evermind.server.ApplicationClientInitialContextFactory.getInitialContext(ApplicationClientInitialContextFactory.java:149)
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
    at javax.naming.InitialContext.init(InitialContext.java:219)
    at javax.naming.InitialContext.<init>(InitialContext.java:195)
    at com.seagate.edcs.config.util.LookupUtility.getInitialContext(LookupUtility.java:123)
    at com.seagate.edcs.config.util.LookupUtility.getConfiguration (LookupUtility.java:69)
    at com.seagate.edcs.config.util.LookupUtility.main(LookupUtility.java:135)
    Code Snippet:
    * This method returns the Configuration for the properties set.
    public ArrayList getConfiguration ( ) throws Exception {
    ArrayList arrayList = null;
    try {
    Context context = getInitialContext();
    System.out.println("Context : " + context);
    Object home = context.lookup("java:comp/env/ejb/com.seagate.edcs.config.ejb.ConfigSessionEJBHome");
    System.out.println("Object home : " + home);
    ConfigSessionEJBHome configSessionEJBHome = (ConfigSessionEJBHome)PortableRemoteObject.narrow(home, ConfigSessionEJBHome.class);
    System.out.println("ConfigSessionEJBHome configSessionEJBHome : " + configSessionEJBHome);
    ConfigSessionEJB configSessionEJB =(ConfigSessionEJB)PortableRemoteObject.narrow(configSessionEJBHome.create(), ConfigSessionEJB.class);
    System.out.println("ConfigSessionEJB configSessionEJB : " + configSessionEJB);
    arrayList = configSessionEJB.getAllConfig();
    System.out.println("Context : " + context);
    } catch (Exception ex) {
    System.out.println("Exception Occured");
    throw ex;
    return arrayList;
    * Get an initial context from the JNDI tree.
    private Context getInitialContext() throws NamingException {
    try {
    Hashtable hashtable = new Hashtable();
    hashtable.put("java.naming.factory.initial", "com.evermind.server.ApplicationClientInitialContextFactory");
    hashtable.put("java.naming.provider.url", "ormi://seagate.mil-shivas-270.am.ad.seagate.com/home"); // if we won't specify the port, it considers the default port
    hashtable.put("java.naming.security.principal","ias_admin");
    hashtable.put("java.naming.security.credentials","ias123");
    return new InitialContext(hashtable);
    } catch (NamingException ne) {
    System.out.println("Exception in InitialContext.");
    throw ne;
    Note:
    1. The user "ias_admin" & password "ias123" are the credential provided for the 'Admin' while installing the Oracle App Server and using these credentials I'm able to bring the Admin Console. Also, added new user 'guest/guest' - assigned this user to the 'admin' group ...
    2. Since its a local lookup, there is no need to specify the credentials, but at runtime a dialog box pops up prompting to enter the 'userid/password' and when I enter the crendtials, I get the exception as stated. [In case of Servlet - EJB lookup, I'm not specifying any credentials]
    Are there are any configuration parameters which I need to provide in any of the .xml? Could you please let me know the fix for the same.
    Regards,
    Kafeel/-

    Please use the OS {forum:id=210}

Maybe you are looking for