Getting http session attributes

Hello,
Perhaps the question here may sound stupid, but I have real problem with that:
Is it possible to obtain http session attributes from the client side
(and even worse) in other languages like VB or VC++? What i mean is that after creating Http session by servlet, and setting some attributes, is it possible to get them by VC or VB app? Thanks in advance :)

What i mean is that after creating Http session by servlet, and >setting some attributes, is it possible to get them by VC or VB app? >Thanks in advance :) What do you mean by "VC or VB app" ?
A desktop app written in VC or VB ? a web app in VBscript/ASP ? (but as far as I know there is no web language based on VC, unless you're talking about executable CGIs that can be written in any language).
Assuming that you talk about VB-ASP, I don't think it possible "out of the box" to retrieve session variables created by a servlet in an ASP page.
That would be possible if HTTP supported sessions.
Sessions are implemented at the application level on top of HTTP; they reside in the application that handles requests. Outside it, they don't exist.
It doesn't mean that you can't do that, but that you have to do that using HTTP constructs like URL rewriting or form submission.
For example you could set session variables in a JSP page, and then forward the request to an ASP page through a GET request with all session variables written in the URL.

Similar Messages

  • How to get HTTP session in Applcation Module IMPL file

    Hi Guys,
    Can any one tell me how to get HTTP session in Applcation Module IMPL file ?
    thnks

    You can, but that's not a best practice.
    Re: How to reach HttpContext from model Project

  • How can I flag HTTP session attributes to not be replicated ?

              WLS 5.1 SP8 - In memory replication of a stateful servlet. Is
              there any way to flag data that has been, or is being, loaded into
              a HTTP session so as to not be replicated ? It's a long story,
              but we have some data loaded into a hashtable, more specifically
              a Properties object, stored in our session. With the hastable
              already loaded into the HTTP session, weblogic does not detect
              when we add values to the table, and therefore does not replicate
              the changes. Which is ok since WLS is working as designed. To
              get around this we load the hashtable back into the session everytime
              we add a value to the hashtable. Yup, I know that's ugly. Anyway,
              what I'm trying to find out if is there is an attribute that we
              can set to indicate, to not replicate this data or that data.
              Something along the lines of a attribute on a per hastable value
              basis. For example, I load value A into my hashtable, then I
              need to put my hashtable into the session to get it replicated.
              Next I load value B into the hastable, and again to get it replicated
              I have to load the entire hashtable back into the session. The
              problem here is that the entire table gets replciated. Does anyone
              know if I can set an attribute on value A, when I'm adding value
              B, so as to not replicate value A when I reload the table ? Of
              course all goal is to not store so much data in the session, but
              I'm trying to find a work around until that is completed.
              Thanks,
              David
              

              Where can I find documentation on the details of how Weblogic decides what will
              be replicated in the HTTPSession object (for example, it only replicates attributes
              which are set or updated using "setAttribute()"?
              Prasad Peddada <[email protected]> wrote:
              >Robert,
              >
              > It is true that we replicate only when you call setAttribute in case
              >of servlets.
              >
              >In case of EJB it is slightly different. EJB sends diff's across the
              >wire. It doesn't
              >replicate the entire state with every request.
              >
              >-- Prasad
              >
              >Chris Palmer wrote:
              >
              >> I think Viresh was referring to modifying part of one attribute causing
              >the whole
              >> of that attribute (i.e. the hashtable) to be replicated.
              >>
              >> Is it actually true though that the behaviour would be different in
              >a stateful
              >> session EJB? I had assumed that the WHOLE ejb state would be replicated
              >each time
              >> (i.e. after each invocation), without even the benefit of having a
              >mechanism such
              >> as setAttribute() to flag the attributes that had changed...
              >>
              >> Chris
              >>
              >> Robert Patrick wrote:
              >>
              >> ? Huh? Since when does it always replicate the entire HttpSession?
              > We were
              >> ? told that it uses a hook in the setAttribute() call to determine
              >which
              >> ? attributes have changed and only replicates those attributes. I
              >know this to
              >> ? be the case because if I retrieve a previously stored attribute from
              >the
              >> ? HttpSession and modify it, my changes do not get replicated unless
              >I call
              >> ? setAttribute again...
              >> ?
              >> ? Robert
              >> ?
              >> ? Viresh Garg wrote:
              >> ?
              >> ? ? Servlet sessions don't work on diffs, so no matter what you do,
              >entire
              >> ? ? Hashtable will be replicated. If you want the optimization for
              >only
              >> ? ? replicating the diff ( the stuff that has changed between 2 updates)
              >,
              >> ? ? consider using stateful session bean and having hashtable part
              >of
              >> ? ? conversational state of stateful session bean.
              >> ? ?
              >> ? ? The solution that you suggested on your own for your problem is
              >not ugly
              >> ? ? as the same solution is used by many customers that I know of.
              >This is
              >> ? ? particularly a problem for people that use Java Beans and use the
              >set
              >> ? ? Property directive of Java Bean in JSP. There also in our auto
              >generated
              >> ? ? code, we put the JavaBean back in HTTP Session, when a setter is
              >called to
              >> ? ? enforce replication.
              >> ? ?
              >> ? ? Keep in mind that whatever we do for replication, we want to support
              >it
              >> ? ? using ONLY standard servlet API and we don't want to introduce
              >any WLS
              >> ? ? specific API to achieve this, and so putting value back in session
              >is the
              >> ? ? only way.
              >> ? ?
              >> ? ? Viresh Garg
              >> ? ? Principal Developer Relations Engineer
              >> ? ? BEA Systems
              >> ? ?
              >> ? ? Dave Javu wrote:
              >> ? ?
              >> ? ? ? WLS 5.1 SP8 - In memory replication of a stateful servlet.
              >Is
              >> ? ? ? there any way to flag data that has been, or is being, loaded
              >into
              >> ? ? ? a HTTP session so as to not be replicated ? It's a long story,
              >> ? ? ? but we have some data loaded into a hashtable, more specifically
              >> ? ? ? a Properties object, stored in our session. With the hastable
              >> ? ? ? already loaded into the HTTP session, weblogic does not detect
              >> ? ? ? when we add values to the table, and therefore does not replicate
              >> ? ? ? the changes. Which is ok since WLS is working as designed.
              >To
              >> ? ? ? get around this we load the hashtable back into the session everytime
              >> ? ? ? we add a value to the hashtable. Yup, I know that's ugly.
              >Anyway,
              >> ? ? ? what I'm trying to find out if is there is an attribute that
              >we
              >> ? ? ? can set to indicate, to not replicate this data or that data.
              >> ? ? ? Something along the lines of a attribute on a per hastable value
              >> ? ? ? basis. For example, I load value A into my hashtable, then
              >I
              >> ? ? ? need to put my hashtable into the session to get it replicated.
              >> ? ? ? Next I load value B into the hastable, and again to get it replicated
              >> ? ? ? I have to load the entire hashtable back into the session. The
              >> ? ? ? problem here is that the entire table gets replciated. Does
              >anyone
              >> ? ? ? know if I can set an attribute on value A, when I'm adding value
              >> ? ? ? B, so as to not replicate value A when I reload the table ?
              >Of
              >> ? ? ? course all goal is to not store so much data in the session,
              >but
              >> ? ? ? I'm trying to find a work around until that is completed.
              >> ? ? ? Thanks,
              >> ? ? ? David
              >
              

  • Getting a session-attribute

    Hi
    I have managed to store a session-attribute containing user-info:
         HttpSession session = request.getSession();
         session.setAttribute(Constants.USER_KEY, user);
    when the current user gets to the mainmenu I want to show different content depending the users authority, problem :
    How do I in my menubean (extending org.apache.struts.action.ActionForm)
    retrieve this users sessionvalues ?
    I can get the servlet but I can't figure out how to get hold of the session
    thanks in advance

    Hi,
    Set you session variable like this and put it in a session for you to read it at a later stage:
    HttpSession session = request.getSession();
    session.setAttribute("USER_KEY", user);
    Read it from you jsp/servlet/bean like:
    HttpSession session = request.getSession();
    String usr_key = (String)session.getAttribute("USER_KEY");
    HTH

  • Define HTTP Session Attribute in a Custom Authenticator

    Hello everyone I developed sucessefully a Custom Authenticator for WLS10 that interacts with a web service.
    But now I need to provide an object to the web applications with the some user information.
    I was wondering defining the object in the HTTP Session but I dont know how to do it via de LoginModule of the custom authenticator.
    Can anyone provide me some tips?
    thanks in advance.

    What kind of user information do you need to pass on to the webapplication ? username can be retrieved by request.getRemoteUser() (after successful login).
    May be you need to clarify little bit more on what you want to achieve.
    -Utpal

  • API fer getting session attributes

    Is there an API for getting a session attribute? I want to use the API in a dynmaic page portlet to get a specific session attribute.
    Thank you.

    following site has all the APIs you can use. Hope this helps.
    http://portalstudio.oracle.com/pls/ops/docs/FOLDER/COMMUNITY/PDK/PLSQL/DOC/PLDOC_9026/INDEX.HTML

  • HTTP Session replication problem

    Hi all,
    After 3 days trying to make the http session replication work in my cluster is time to ask some help.
    I´m trying to make a simple application (only a servlet) simulate a http session replication.
    I´ve investigated all the possible problems that i encountered in google :
    Here is my multicast tests :
    SERVER 1
    D:\>java -cp d:\bea\weblogic92\server\lib\weblogic.jar utils.MulticastTest -N SE
    RVER1 -A 237.0.0.1 -p 12809
    ***** WARNING ***** WARNING ***** WARNING *****
    Do NOT use the same multicast address as a running WLS cluster.
    Starting test. Hit any key to abort
    Using multicast address 237.0.0.1:12809
    Will send messages under the name SERVER1 every 2 seconds
    Will print warning every 600 seconds if no messages are received
    I (SERVER1) sent message num 1
    I (SERVER1) sent message num 2
    Received message 2 from SERVER1
    I (SERVER1) sent message num 3
    Received message 3 from SERVER1
    I (SERVER1) sent message num 4
    Received message 4 from SERVER1
    I (SERVER1) sent message num 5
    Received message 5 from SERVER1
    I (SERVER1) sent message num 6
    Received message 6 from SERVER1
    I (SERVER1) sent message num 7
    Received message 7 from SERVER1
    I (SERVER1) sent message num 8
    Received message 8 from SERVER1
    I (SERVER1) sent message num 9
    Received message 9 from SERVER1
    I (SERVER1) sent message num 10
    Received message 10 from SERVER1
    Received message 11 from SERVER1
    I (SERVER1) sent message num 11
    I (SERVER1) sent message num 12
    Received message 12 from SERVER1
    I (SERVER1) sent message num 13
    Received message 13 from SERVER1
    Received message 14 from SERVER1
    I (SERVER1) sent message num 14
    I (SERVER1) sent message num 15
    Received message 15 from SERVER1
    I (SERVER1) sent message num 16
    Received message 16 from SERVER1
    SERVER 2
    D:\>java -cp d:\bea\weblogic92\server\lib\weblogic.jar utils.MulticastTest -N SE
    RVER2 -A 237.0.0.1 -p 12809
    ***** WARNING ***** WARNING ***** WARNING *****
    Do NOT use the same multicast address as a running WLS cluster.
    Starting test. Hit any key to abort
    Using multicast address 237.0.0.1:12809
    Will send messages under the name SERVER2 every 2 seconds
    Will print warning every 600 seconds if no messages are received
    I (SERVER2) sent message num 1
    I (SERVER2) sent message num 2
    Received message 2 from SERVER2
    I (SERVER2) sent message num 3
    Received message 3 from SERVER2
    I (SERVER2) sent message num 4
    Received message 4 from SERVER2
    I (SERVER2) sent message num 5
    Received message 5 from SERVER2
    I (SERVER2) sent message num 6
    Received message 6 from SERVER2
    I (SERVER2) sent message num 7
    Received message 7 from SERVER2
    I (SERVER2) sent message num 8
    Received message 8 from SERVER2
    I (SERVER2) sent message num 9
    Received message 9 from SERVER2
    I (SERVER2) sent message num 10
    Received message 10 from SERVER2
    I (SERVER2) sent message num 11
    Received message 11 from SERVER2
    I (SERVER2) sent message num 12
    Received message 12 from SERVER2
    Weblogic.XML descriptor
    <session-descriptor>
              <session-param>
                   <param-name>PersistentStoreType</param-name>
                   <param-value>replicated</param-value>
              </session-param>
    </session-descriptor>
    CODE of the Servlet
    HttpSession session = request.getSession();
              String sessionIdentif = (String)session.getAttribute("SESSIONIDENTIF");
              boolean boolNewSession = true;
              if(sessionIdentif == null) {
                   session.setAttribute("SESSIONIDENTIF", "1234567890");
              } else
                   boolNewSession = false;
    As you can see the object that i put in session is a String, so Serializable....
    All the requirements are validated (i think...) but it still not working ... i get the SESSION ID : WvHQMKzBh9T35BPhGJxyhQtGks5Q3qJmxnJwGn8mn7V24FM92cnh!949557342! NONE !1284141857480
    And the NONE said that the session isn´t replicated.
    Any idea what´s wrong with my try of getting http session replication working??
    cheers,

    Hi,
    Thanks for your help.
    I´ve tried your application with your proxy application but still no work...
    I´m getting :
    ####<13/Set/2010 15H59m BST> <Debug> <Replication> <DST01VS51> <VIACTT2> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1284389948055> <000000> <Creating primary 1678977133045201960>
    ####<13/Set/2010 15H59m BST> <Debug> <ReplicationDetails> <DST01VS51> <VIACTT2> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1284389948055> <000000> <Unable to create secondary for 1678977133045201960 on null>
    ####<13/Set/2010 15H59m BST> <Debug> <ReplicationDetails> <DST01VS51> <VIACTT2> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1284389948181> <000000> <Unable to create secondary for 1678977133045201960 on null>
    In my early post i forgot to mention that i´m using an Apache 2.2 in the front-end with Weblogic 9.2 (cluster).
    What is happening in this weblogic configuration so that this session replication don´t work.
    cheers,

  • How to get from data entered on a form to a session attribute

    I have a jsp with a form with fields that are updated by the user.
    The values are in the fields value as I expected.
    Example. document.frm.Name.value = "Me"
    How do I populate a session variable with document.frm.Name.value?
    I think I have to do a request.getParameter("Name") followed by a
    session.SetAttribute. But the request.getParameter does not get populated with the latest value in document.frm.Name.value.
    Any idea is welcomed. Thanks
    Claudiine

    Below is the code:
    What I want to do is save in the session attribute "mailToAddressList" whatever the user types in the textarea "MailTo"
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.util.*;
    import java.sql.*;
    import java.text.*;
    import java.io.*;
    import com.cname.apl.*;
    public class DealTeamServlet extends HttpServlet {
    private appUtil util ;
    private java.sql.Connection conn ;
    private static String dbUrl ;
    private static String dbUid ;
    private static String dbPwd ;
    private static String mailFromAddressList ;
    private static String mailToAddressList ;
    private static String mailCcAddressList ;
    private static String mailBccAddressList ;
    private static String mailSubject ;
    SimpleDateFormat SDF = new SimpleDateFormat("d-MMM-yyyy");
    public void init(ServletConfig config) throws ServletException {
    super.init(config);
    dbUrl = config.getInitParameter("dbUrl");
    dbUid = config.getInitParameter("dbUid");
    dbPwd = config.getInitParameter("dbPwd");
    mailFromAddressList = config.getInitParameter("mailFromAddressList");
    mailToAddressList = config.getInitParameter("mailToAddressList");
    mailCcAddressList = config.getInitParameter("mailCcAddressList");
    mailBccAddressList = config.getInitParameter("mailBccAddressList");
    mailSubject = config.getInitParameter("mailSubject");
    if (dbUrl == null)
    dbUrl = "*" ;
    if (dbUid == null)
    dbUid = "*" ;
    if (dbPwd == null)
    dbPwd = "*" ;
    if (mailFromAddressList == null || mailFromAddressList.equals("*"))
    mailFromAddressList = "" ;
    if (mailToAddressList == null || mailToAddressList.equals("*"))
    mailToAddressList = "" ;
    if (mailCcAddressList == null || mailCcAddressList.equals("*"))
    mailCcAddressList = "" ;
    if (mailBccAddressList == null || mailBccAddressList.equals("*"))
    mailBccAddressList = "" ;
    if (mailSubject == null || mailSubject.equals("*"))
    mailSubject = "" ;
    protected void processRequest(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, java.io.IOException {
    HttpSession session = request.getSession(true) ;
    String msgBody = (String) request.getParameter("msgBody");
    String uid = (String) request.getParameter("uid");
    String key = (String) request.getParameter("key");
    Boolean isAuthorized = (Boolean) session.getAttribute("isAuthorized");
    java.io.PrintWriter out = response.getWriter();
    if (msgBody == null) msgBody = "" ;
    response.setContentType("text/html");
    if (uid == null || key == null) {
    isAuthorized = new Boolean(false);
    if ( isAuthorized == null ) {
    util = new appUtil();
    conn = util.getConnection(dbUrl, dbUid, dbPwd) ;
    isAuthorized = util.isAuthorized(conn, uid, key);
    util.closeConnection(conn) ;
    if ( isAuthorized.booleanValue() ) {
    session.setAttribute("isAuthorized", new Boolean(true));
    java.sql.Timestamp serverTime = util.getServerTime(conn) ;
    java.sql.Date now = new java.sql.Date(serverTime.getTime());
    int idEntry = Integer.parseInt(msgBody);
    mailToAddressList = request.getParameter("MailTo");
    out.println("<html>");
    out.println("<head>");
    out.println("<title>Team Members</title>");
    out.println("<SCRIPT LANGUAGE=JavaScript>");
    out.println("function open_window() {");
    out.println("document.domain = \"ny.cname.com\"");
    out.println("var loc = \"http://peoplelkp.ny.cname.com/peoplelkp/PDLookupService?&emil2=eMail&form=frm&launch=myRoutine()&csr=1&srch=1&adv=1&wc=y&pump=\"");
    out.println("loc = loc + document.frm.Name.value");
    out.println("var w = window.open(loc,\"Model_Details\",\"scrollbars,width=400,height=450,resizable=yes\")");
    out.println("return;");
    out.println("}");
    out.println("function myRoutine() {");
    out.println("document.frm.MailTo.value=document.frm.MailTo.value+\",\"+document.frm.eMail.value;");
    out.println("}");
    out.println("function submitForm() {");
    out.println("alert('submit form')");
    out.println("var mailAdd = document.frm.MailTo.value");
    out.println("alert('mailAdd='+mailAdd);");
    out.println("if ( mailAdd.length == 0 || mailAdd.indexOf(' ') == 0 || mailAdd.indexOf('.com') == -1 || mailAdd.indexOf('@') == -1 ) {" );
    out.println("alert('The To: field must be populated. No space are allowed. Email addresses must have valid format. Example: [email protected]')");
    out.println("document.all.frm.MailTo.focus();");
    out.println("return false;");
    out.println("}");
    out.println("return true;");
    out.println("}");
    out.println("function UpdateMailTo() {");
    out.println("alert ('I am in UpdateMailTo='+document.frm.MailTo.value);");
    out.println("}");
    out.println("</SCRIPT>");
    out.println(util.getStyleSheet());
    out.println("</head>");
    out.println("<body bgcolor='silver'>");
    out.println("<form name='frm' action='SendMail' method='post'>");
    out.println("<b>Team Members</b>");
    out.println("<tr>");
    out.println("<TABLE cellpadding='0' cellspacing='0' border='0'>");
    out.println("<tr>");
    out.println("<td align='right'><b>Subject:  </b></td>");
    out.println("<td>Deal Team Members Cleared by Conflicts</td>");
    out.println("</tr><br>");
    StringBuffer bod = new StringBuffer("");
    SimpleDateFormat SDF = new SimpleDateFormat("d-MMM-yyyy");
    try {
    /*get header information*/
    CallableStatement st = conn.prepareCall("{call apl_get_sp ?}");
    st.setInt(1, idEntry);
    ResultSet rs = st.executeQuery();
    int id = 0;
    int dw = 0;
    String cde_proj = "";
    String nm_title = "";
    String nm_long = "";
    String empl = "";
    String sid = "";
    int userid = 0;
    String email_pr = "";
    while ( rs.next() ) {
    id = rs.getInt("id_entry");
    dw = rs.getInt("id_dealworks");
    cde_proj = rs.getString("cde_proj");
    nm_title = rs.getString("nm_title");
    nm_long = rs.getString("nm_long");
    empl = rs.getString("empl_name");
    sid = rs.getString("id_standard");
    email_pr = rs.getString("id_email_ext_unix");
    mailToAddressList = email_pr.trim();
    out.println("<tr><td align='right'><b>To:  </b></td>");
    out.println("<td><textarea name='MailTo' cols='50' rows='2'>"+mailToAddressList+ "</textarea></td>");
    out.println("<td>  </td>");
    out.println("<td><input type='button' value='Save' onClick='UpdateMailTo()'></td>");
    out.println("</tr>");
    // out.println("request.setAttribute('mailadd',document.frm.MailTo.value);");
    // mailToAddressList = request.getParameter("mailadd");
    out.println("<tr><td align='right'><b>Name:  </b></td>");
    out.println("<td><INPUT NAME='Name' VALUE='' size=65 ></td>");
    out.println("<td>  </td>");
    out.println("<td><input type='button' value='Search' onClick='open_window()'></td>");
    out.println("</tr>");
    out.println("<tr><td align='right'><b>EMail:  </b></td>");
    out.println("<td><INPUT NAME='eMail' VALUE='' size=65'></td>");
    out.println("</tr>");
    if (rslt != null) rslt.close() ;
    if (stmt != null) stmt.close() ;
    }/*end try*/
    catch ( Exception e) {
    System.out.println(e) ;
    getServletContext().log(e.toString());
    out.println("<td colspan='5' align='right'><input type='submit' value='Send email' onClick='submitForm()'></td>");
    out.println("</tr>");
    out.println("</table>");
    out.println("</form>");
    out.println("</body>");
    out.println("</html>");
    mailSubject = "Team Members";
    String body = "testing";
    session.setAttribute("mailFromAddressList", mailFromAddressList);
    session.setAttribute("mailToAddressList", mailToAddressList);
    session.setAttribute("mailCcAddressList", mailCcAddressList);
    session.setAttribute("mailBccAddressList", mailBccAddressList);
    session.setAttribute("mailSubject", mailSubject);
    session.setAttribute("mailBody", body);
    else {
    session.setAttribute("isAuthorized", new Boolean(false));
    out.println("You are not authorized.");
    //out.close();
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, java.io.IOException {
    processRequest(request, response);
    protected void doPost(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, java.io.IOException {
    processRequest(request, response);
    public String getServletInfo() {
    return "Short description";
    }

  • [svn:bz-trunk] 21394: bug fix for watson 2887837 Not getting duplicate session detected error when same flex client id is used from two different HTTP sessions in CRX .

    Revision: 21394
    Revision: 21394
    Author:   [email protected]
    Date:     2011-06-16 12:34:13 -0700 (Thu, 16 Jun 2011)
    Log Message:
    bug fix for watson 2887837 Not getting duplicate session detected error when same flex client id is used from two different HTTP sessions in CRX.
    get the sessions id before we invalidate the duplicate session.
    Checkintests pass
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/endpoints/BaseHTTPEndpoint.java

    For our profect I think this issue was caused as follows:
    Believing that remoting was full asynchronous we fired a 2 or 3 remote calls to the server at the same time ( within the same function ) - usually when the users goes to a new section of the app.
    This seemed to trigger the duplicate http session error since according to http://blogs.adobe.com/lin/2011/05/duplication-session-error.html  two remote calls arriving before a session is created will cause 2 sessions to be created.
    Our current solution ( too early to say it works ) is to daisy chain the multiple calls together .
    Also there seemed to be an issue where mobile apps that never quit ( thanks Apple! )  caused the error when activated after a few hours.
    I guess the session expires on the server and the error above occurs on activation.
    So the mobile apps now ping the server with a remote call when activated after sleeping for more than one hour.
    All duplicate http errors are silently caught and reported.
    Fingers crossed we won't get any more!

  • Get Http Request in Session Listener?

    Is it possible get Http Request in Session Listener when session is created? I need to get cookies when session is created.
    anyone knows?

    No, it is not possible.

  • URGET!!! Get Session Attribute On Form

    Hi alls,
    I develope application with Forms 9i and JSP.My Application Program is developed by Forms 9i but Menu,that call application program,is developed by JSP.I knew that if I want to call a Form from JSP,I have to append &otherparams on URL.
    My Problems is :
    1.I want to get some parameters,is seted to session attribute in JSP,from Menu to Forms and don't let the users to see these parameters on URL. HOW CAN I DO? (URGENT!!!!)
    2.If I want the Menu always display on top and application display on botton of browser. HOW CAN I DO?
    Thank you for advance.
    PS. Menu develop in dropdown style,it will expand(drop) when move mouse on it.

    Hi,
    1.I want to get some parameters,is seted to session attribute in JSP,from Menu to Forms and don't let the users to see these parameters on URL. HOW CAN I DO? (URGENT!!!!)
    You can't get session attribute from Forms because it runs as an Applet in the browser and does not have access to the server side request object.
    You can access request parameters that are used to call Forms, but that's it.
    2.If I want the Menu always display on top and application display on botton of browser. HOW CAN I DO?
    Use HTML frames
    Frank

  • Accessing session attribute in output jsp page

    Hi i am not getting any output in jsp page...
    i am getting just heading
    i think some problem with Session attribute..
    if so how to access session been in jsp page
    my code is here
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%--
    The taglib directive below imports the JSTL library. If you uncomment it,
    you must also add the JSTL library to the project. The Add Library... action
    on Libraries node in Projects view can be used to add the JSTL 1.1 library.
    --%>
    <%--
    <%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
    --%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Tauvex Search Output</title>
    </head>
    <body>
    Tauvex Search Output
    <table>
    <c:forEach items="${myDataList}" var="myData">
    <tr>
    <td>${myData.Fitsfilename}</td>
    <td>${myData.RA_START}</td>
    <td>${myData.RA_END}</td>
    <td>${myData.DEC_START}</td>
    <td>${myData.DEC_END}</td>
    <td>${myData.telescope}</td>
    <td>${myData.STARTOBS}</td>
    <td>${myData.ENDOBS}</td>
    <td>${myData.FILTER}</td>
    </tr>
    </c:forEach>
    </table>
    <%--
    This example uses JSTL, uncomment the taglib directive above.
    To test, display the page like this: index.jsp?sayHello=true&name=Murphy
    --%>
    <%--
    <c:if test="${param.sayHello}">
    <!-- Let's welcome the user ${param.name} -->
    Hello ${param.name}!
    </c:if>
    --%>
    </body>
    </html>
    plz reply soon
    thanks a lot

    this is what i set in servlet
    request.setAttribute("myDataList", myDataList);
    request.getRequestDispatcher("someJspFile.jsp").forward(request, response);
    how can i access that session attribute in jsp

  • Error in retrieving session attribute for ejb remote in clustered env

              We store EJB remote object in session and differnt clients retrieve it from sessionbefore
              making a business method call. This seems to work in most cases but sometimes
              it gives the exception attached. This happens only in a clustered environment.What
              has been observed is that if we put the remote object inside a hashtablewhich
              in-turn is stored in session retrieval from hashtable does not give thisproblem.
              Any suggestion / solution would be greatly appreciated.
              Regards,
              Shilpa
              The exception Stack trace is attachedjava.rmi.NoSuchObjectException: Unable to
              locate EJBHome: 'BalconHome' on server:'t3://176.19.183.6,176.19.183.15:9616 at
              weblogic.ejb20.internal.HomeHandleImpl.getEJBHome(HomeHandleImpl.java:80) at weblogic.ejb20.internal.HandleImpl.getEJBObject(HandleImpl.java:184)
              at weblogic.servlet.internal.session.SessionData.getAttribute(SessionData.java:395)
              at com.chase.ccs.util.AccountInfoAccessor.setCurrentAccountAttributeBalcon(AccountInfoAccessor.java:362)
              at com.chase.ccs.util.ModelAccessor.initBlaconOfferModel(ModelAccessor.java:311)
              at com.chase.ccs.balancetransfer.OfferPortlet.service(OfferPortlet.java:88) at
              com.chase.ccs.balancetransfer.OfferView.pageStart(OfferView.java:65) at com.chase.ccs.util.ModuleStarter.doAllPageStart(ModuleStarter.java:236)
              at jsp_servlet._templates._template0005._UXaQVaXTUaSYaWaSRZfdXbWSfYXbTRQb.__ccs_mm_tgl_pfp_grid._jspService(__ccs_mm_tgl_pfp_grid.java:316)
              at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
              at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
              at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:482)
              at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:308)
              at weblogic.servlet.jsp.PageContextImpl.include(PageContextImpl.java:116) at com.epicentric.servlets.ServletUtils.include(ServletUtils.java:150)
              at com.epicentric.template.Style.execute(Style.java:538) at com.epicentric.taglib.html.IncludeGridTag.doStartTag(IncludeGridTag.java:57)
              at jsp_servlet.__index._jspService(__index.java:560) at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
              at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
              at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
              at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:242)
              at com.epicentric.servlets.stackable.SiteDispatcherServlet.service(SiteDispatcherServlet.java:195)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
              at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
              at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2546)
              at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2260)
              at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              

              The EJB is stateful session EJB. Have seen some posts pointing to problems
              with
              stateful session EJB and cluster and the suggested solution was SP4 (we are
              on 6.1 SP3).
              Hope this gets more clarity (and some solutions!!!).
              regards,
              Rajesh / Shilpa
              "Cameron Purdy" <[email protected]> wrote in message
              news:[email protected]...
              > It's probably caused by the fact that the session attributes get
              serialized
              > when they are in a cluster. (Something to do with ser/deser process?)
              >
              > Peace,
              >
              > Cameron Purdy
              > Tangosol, Inc.
              > http://www.tangosol.com/coherence.jsp
              > Tangosol Coherence: Clustered Replicated Cache for Weblogic
              >
              >
              > "Shilpa" <[email protected]> wrote in message
              > news:[email protected]...
              > >
              > > We store EJB remote object in session and differnt clients retrieve it
              > from sessionbefore
              > > making a business method call. This seems to work in most cases but
              > sometimes
              > > it gives the exception attached. This happens only in a clustered
              > environment.What
              > > has been observed is that if we put the remote object inside a
              > hashtablewhich
              > > in-turn is stored in session retrieval from hashtable does not give
              > thisproblem.
              > > Any suggestion / solution would be greatly appreciated.
              > >
              > > Regards,
              > > Shilpa
              > >
              > > The exception Stack trace is attachedjava.rmi.NoSuchObjectException:
              > Unable to
              > > locate EJBHome: 'BalconHome' on
              > server:'t3://176.19.183.6,176.19.183.15:9616 at
              > >
              weblogic.ejb20.internal.HomeHandleImpl.getEJBHome(HomeHandleImpl.java:80)
              > at weblogic.ejb20.internal.HandleImpl.getEJBObject(HandleImpl.java:184)
              > > at
              >
              weblogic.servlet.internal.session.SessionData.getAttribute(SessionData.java:
              > 395)
              > > at
              >
              com.chase.ccs.util.AccountInfoAccessor.setCurrentAccountAttributeBalcon(Acco
              > untInfoAccessor.java:362)
              > > at
              >
              com.chase.ccs.util.ModelAccessor.initBlaconOfferModel(ModelAccessor.java:311
              > )
              > > at
              > com.chase.ccs.balancetransfer.OfferPortlet.service(OfferPortlet.java:88)
              at
              > > com.chase.ccs.balancetransfer.OfferView.pageStart(OfferView.java:65) at
              > com.chase.ccs.util.ModuleStarter.doAllPageStart(ModuleStarter.java:236)
              > > at
              >
              jsp_servlet._templates._template0005._UXaQVaXTUaSYaWaSRZfdXbWSfYXbTRQb.__ccs
              > mmtgl_pfp_grid._jspService(__ccs_mm_tgl_pfp_grid.java:316)
              > > at weblogic.servlet.jsp.JspBase.service(JspBase.java:27) at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :265)
              > > at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :200)
              > > at
              >
              weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImp
              > l.java:482)
              > > at
              >
              weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImp
              > l.java:308)
              > > at
              weblogic.servlet.jsp.PageContextImpl.include(PageContextImpl.java:116)
              > at com.epicentric.servlets.ServletUtils.include(ServletUtils.java:150)
              > > at com.epicentric.template.Style.execute(Style.java:538) at
              >
              com.epicentric.taglib.html.IncludeGridTag.doStartTag(IncludeGridTag.java:57)
              > > at jsp_servlet.__index._jspService(__index.java:560) at
              > weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
              > > at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :265)
              > > at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :200)
              > > at
              >
              weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImp
              > l.java:242)
              > > at
              >
              com.epicentric.servlets.stackable.SiteDispatcherServlet.service(SiteDispatch
              > erServlet.java:195)
              > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :265)
              > > at
              >
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > :200)
              > > at
              >
              weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
              > ntext.java:2546)
              > > at
              >
              weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
              > :2260)
              > > at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at
              > weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              >
              >
              

  • URGENT http session HELP PLEASE

    Hello all.
    i work in http session...after i redirect in https(login.jsp for example)
    in JavaBean for Login.jsp try get connection with all object or JavaBeans from last http session ...but i cannot do it.
    Where my problem ?
    How i can have access across sessions?
    Help me please.

    i don't understand your meaning exactly,but i think what you mean is maybe to make a bean accessible across the session?is that right?if yes,you can set the scope attribute to session,such as:
    <jsp:useBean id="..." scope="session" class="...."/>

  • Java.lang.NullPointerException: IWSHttpSession: Session attribute name or v

    Hi ,
    I could deploy Web module (war) file on iPlanet 6.0 sp7. But when I try to run the app in the browser, I get the following error :
    Has anyone come across this same issue?
    Thanks.
    Peter
    p.s. I do not have this issue with Sun One 7.0 Ap Server.
    Start of Server Log
    [30/Jun/2004:09:59:15] info ( 1540): successful server startup
    [30/Jun/2004:09:59:15] info ( 1540): iPlanet-WebServer-Enterprise/6.0SP8 B04/20/2004 07:13
    [30/Jun/2004:09:59:15] info ( 1540): Installing a new configuration
    [30/Jun/2004:09:59:15] info ( 1540): [LS ls1] http://gutierc, port 90 ready to accept requests
    [30/Jun/2004:09:59:15] info ( 1540): A new configuration was successfully installed
    [30/Jun/2004:09:59:15] info ( 1540): Internal error: unable to create JVM
    [30/Jun/2004:09:59:15] failure ( 1540): Failure to load JVM (check your JRE)
    [30/Jun/2004:09:59:15] failure ( 1540): Late initialization failed: Error running init function(late) NSServletLateInit: unknown error
    [30/Jun/2004:09:59:15] info ( 1540):  Suspend Httpd Service
    [30/Jun/2004:10:04:29] info (  508): successful server startup
    [30/Jun/2004:10:04:29] info (  508): iPlanet-WebServer-Enterprise/6.0SP8 B04/20/2004 07:13
    [30/Jun/2004:10:04:29] info (  508): Installing a new configuration
    [30/Jun/2004:10:04:30] info (  508): [LS ls1] http://gutierc, port 90 ready to accept requests
    [30/Jun/2004:10:04:30] info (  508): A new configuration was successfully installed
    [30/Jun/2004:10:04:32] info (  508): Using the Java HotSpot(TM) Server VM v1.3.1_12 from Sun Microsystems Inc.
    [30/Jun/2004:10:04:32] info (  508): Java VM classpath: c:/program1/sun/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSServletLayer.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSJavaUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/AdminNativeUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSJavaMiscUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/servlet.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/servlet-2.3-filters-api.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jsp092.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jaxp.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/crimson.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/xalan.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jspengine.jar;
    [30/Jun/2004:10:04:32] info (  508): Loading IWSSessionManager by default.
    [30/Jun/2004:10:04:32] info (  508): IWSSessionManager: Maximum number of sessions is 1000
    [30/Jun/2004:10:04:33] info (  508): Successfully initialized web application environment (web-apps.xml) for virtual server (https-gutierc)
    [30/Jun/2004:10:40:36] warning (  508): for host 172.20.37.58 trying to GET /AFOWeb/start.do, send-file reports: can't find c:/program1/sun/iPlanet/Servers/docs-90/AFOWeb/start.do (File not found)
    [30/Jun/2004:12:18:51] info (  508):  Suspend Httpd Service
    [30/Jun/2004:12:18:52] info (  508): vs(https-gutierc)Closing the web applications
    [30/Jun/2004:12:19:03] info ( 1848): successful server startup
    [30/Jun/2004:12:19:03] info ( 1848): iPlanet-WebServer-Enterprise/6.0SP8 B04/20/2004 07:13
    [30/Jun/2004:12:19:03] info ( 1848): Installing a new configuration
    [30/Jun/2004:12:19:03] info ( 1848): [LS ls1] http://gutierc, port 90 ready to accept requests
    [30/Jun/2004:12:19:03] info ( 1848): A new configuration was successfully installed
    [30/Jun/2004:12:19:04] info ( 1848): Using the Java HotSpot(TM) Server VM v1.3.1_12 from Sun Microsystems Inc.
    [30/Jun/2004:12:19:04] info ( 1848): Java VM classpath: c:/program1/sun/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSServletLayer.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSJavaUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/AdminNativeUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/NSJavaMiscUtil.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/servlet.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/servlet-2.3-filters-api.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jsp092.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jaxp.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/crimson.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/xalan.jar;c:/program1/sun/iPlanet/Servers/bin/https/jar/jspengine.jar;
    [30/Jun/2004:12:19:04] warning ( 1848): msg_badAlias
    [30/Jun/2004:12:19:04] info ( 1848): Loading IWSSessionManager by default.
    [30/Jun/2004:12:19:04] info ( 1848): IWSSessionManager: Maximum number of sessions is 1000
    [30/Jun/2004:12:19:05] info ( 1848): Adding web application (/AFOWeb) at (C:/Program1/sun/iPlanet/Servers/docs-90/AFOWeb)
    [30/Jun/2004:12:19:06] info ( 1848): Loading IWSSessionManager by default.
    [30/Jun/2004:12:19:06] info ( 1848): IWSSessionManager: Maximum number of sessions is 1000
    [30/Jun/2004:12:19:12] info ( 1848): vs(https-gutierc)servlet 'action' class = 'org.apache.struts.action.ActionServlet' loaded in context = '/AFOWeb'
    [30/Jun/2004:12:19:12] info ( 1848): action: init
    [30/Jun/2004:12:19:21] info ( 1848): Successfully initialized web application environment (web-apps.xml) for virtual server (https-gutierc)
    [30/Jun/2004:12:20:58] failure ( 1848): Internal error: servlet service function had thrown ServletException (uri=/AFOWeb/start.do): javax.servlet.ServletException: IWSHttpSession: Session attribute name or value is null, stack: javax.servlet.ServletException: IWSHttpSession: Session attribute name or value is null
         at org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:545)
         at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:486)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.iplanet.server.http.servlet.NSServletRunner.invokeServletService(NSServletRunner.java:937)
         at com.iplanet.server.http.servlet.WebApplication.service(WebApplication.java:1071)
         at com.iplanet.server.http.servlet.NSServletRunner.ServiceWebApp(NSServletRunner.java:999)
    , root cause: java.lang.NullPointerException: IWSHttpSession: Session attribute name or value is null
         at com.iplanet.server.http.session.IWSHttpSession.setAttribute(IWSHttpSession.java:494)
         at com.infinity.imaging.afo.presentation.action.DoStartAction.execute(DoStartAction.java:45)
         at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:484)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.iplanet.server.http.servlet.NSServletRunner.invokeServletService(NSServletRunner.java:937)
         at com.iplanet.server.http.servlet.WebApplication.service(WebApplication.java:1071)
         at com.iplanet.server.http.servlet.NSServletRunner.ServiceWebApp(NSServletRunner.java:999)

    I am not sure if this solved the problem.
    But now, I am using Sun One Web Server 6.1 sp1.
    You can download it from
    http://wwws.sun.com/software/download/products/4000635d.html
    Try using this and see if the problem gets resolved.
    Peter.

Maybe you are looking for

  • While doing MIRO i am getting an error: Enter a tax jurisdiction code

    Hi, While doing a MIRO, i am getting an error : Enter a tax jurisdiction code Message no. M8757 How to Resolve Pratik

  • How to allign an apDiv with the template centre alligned?

    Hi, I am trying to create a website in Adobe Dreamweaver CS4 but made a website template in Adobe Fireworks which was then imported in. My template was then center alligned with the apDivs placed on it containing all the links/images/rolloevers etc.

  • Image attachments sent to me by another are being downsized

    I'm a freelance designer, and one of my clients sends me all work via e-mail. The last few days, when she sends me images (that she received from another client) they are downsized to a point where I can't even use them. Is there a setting somewhere

  • "Computers" Setup Window Does Not Appear

    ARD has stopped working on my MacBook. Basically, ARD starts up but then doesn't show the computers setup window. All of the options in the menu bar are greyed out. It appears from a knowledgebase article (http://docs.info.apple.com/article.html?artn

  • Problems booting up MBP

    Hi I have a MBP 1.1 2.16 Core Duo... When i turn it on, it powers up because i can hear the fans, however i just get black screen... After a while it will boot up and the drives start spinning etc and all is fine... I have noticed that sometime if i