Portal sessionId to J2EE App

Hello
I have a page in portal which has the menu of my site, when I click on any of the options in the menu I am redirected to an j2ee app in OC4J, but I need to pass the portal sessionId to this app.
Does anybody know how to do that?
Please help me, I am desperate.
Thanks in advance

A little more detail.  Our j2ee is just a war file right now, however we wrap it as an ear to deploy it within the sap app server.  We have our own user interface with Struts/velocity which we want to keep.  However, we want to add some views which can be deployed within the SAP portal container.
So, I am looking for advice on what kind of project i should be setting up within the developer studio, and how I should deploy this.
Thanks,
craig

Similar Messages

  • Portal sessionId to external app

    Hello
    I have a page in portal which has the menu of my site, when I click on any of the options in the menu I am redirected to an j2ee app in OC4J, but I need to pass the portal sessionId to this app.
    Does anybody know how to do that?
    Please help me, I am desperate.
    Thanks in advance

    Use something like this
    <?variable@incontext:link1;.//SERVLET?>
    <fo:basic-link show-destination="new" external-destination="url({$link1})" color="blue" text-decoration="underline"><?NAME?></fo:basic-link>
    Regards,
    Amit.

  • Your tips?  portlet wraping of legacy j2ee apps?

    We're starting the design phase of a portal project that will take 20-40 existing J2ee apps and attempt to put a portlet interface over them.
    The delivered value will be classic portal; tntitlement, preferences, desktop per role, overview portlet and detail portlets listening on user data context events.
    Any tips, your experiences, what not to do, any example portal source etc you can share?
    Thanks, curt

    You can play with avitek portal in sample portals that comes with weblogic
    Seenu.

  • MMS J2ee app made with JBOSS want to use it with JRUN

    Hello fellow developers,
    I am very interested in creating a small website for uploading photos from my cell phone to a j2ee app running on a JRUN 4 server.
    I've downloaded the J2, JSR-212 SAMS Messaging API EJB Reference Implementation, from the nokia site. II also down load an MMSC and SMSC simulator from NOkia, which I believe developers can use in conjunction with testing the above ejb web application.
    Briefly this is what I think is happening so far from reading tid bits here and there like the aritcle in Java Boutique.
    It seems todescribe the SAMS api as being generic enough to accept all clients that supply SPI, which I believe is the interface that verizon, cingular, or that some other cell phone service might provide. This interface allows the forwarding of a text message or media message to another operation ( like yahoo mobile). Thus, when I send my photo to a [email protected], it goes to the MMSC that communicates through SPI say a SAMS J2EE applicaiton running on yahoo, which presents my recently snapped cell phone photo in my yahoo phone album.
    I would like to test this J2ee app I download from nokia. However, in part of the instructions it claims that a person must down load JBOSS 4.0.
    Does any one know if this Nokia J2ee app for JBoss can be used on a JRUN 4?
    Can the NOKIA SMSC/MMSC simulator I downloaded work as well with JRUN4, as I notice the word JBOSS when I was installing this Simulator?
    Does anyone know where, I can get anymore information on SAMS and how to implement it in a simple J2ee app?
    When we can upload a cell phone photofrom the web browser of our phone than we will have arrived!.

    Hello fellow developers,
    I am very interested in creating a small website for uploading photos from my cell phone to a j2ee app running on a JRUN 4 server.
    I've downloaded the J2, JSR-212 SAMS Messaging API EJB Reference Implementation, from the nokia site. II also down load an MMSC and SMSC simulator from NOkia, which I believe developers can use in conjunction with testing the above ejb web application.
    Briefly this is what I think is happening so far from reading tid bits here and there like the aritcle in Java Boutique.
    It seems todescribe the SAMS api as being generic enough to accept all clients that supply SPI, which I believe is the interface that verizon, cingular, or that some other cell phone service might provide. This interface allows the forwarding of a text message or media message to another operation ( like yahoo mobile). Thus, when I send my photo to a myphone#@photo.yahoo.com, it goes to the MMSC that communicates through SPI say a SAMS J2EE applicaiton running on yahoo, which presents my recently snapped cell phone photo in my yahoo phone album.
    I would like to test this J2ee app I download from nokia. However, in part of the instructions it claims that a person must down load JBOSS 4.0.
    Does any one know if this Nokia J2ee app for JBoss can be used on a JRUN 4?
    Can the NOKIA SMSC/MMSC simulator I downloaded work as well with JRUN4, as I notice the word JBOSS when I was installing this Simulator?
    Does anyone know where, I can get anymore information on SAMS and how to implement it in a simple J2ee app?
    When we can upload a cell phone photofrom the web browser of our phone than we will have arrived!.

  • J2EE app server not able to compile JSP

    Hi,
    I have just installed J2EE app server and am trying to deploy a JSP. The following error is generated. can anyone help me please.
    Thank you,
    Deepika.
    org.apache.jasper.JasperException: Unable to compile class for JSP
    No Java compiler was found to compile the generated source for the JSP.
    This can usually be solved by copying manually $JAVA_HOME/lib/tools.jar from the JDK
    to the common/lib directory of the Tomcat server, followed by a Tomcat restart.
    If using an alternate Java compiler, please check its installation and access path.
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:127)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:348)
         org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:424)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:464)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:448)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:551)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:300)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         sun.reflect.GeneratedMethodAccessor82.invoke(Unknown Source)
         sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         java.lang.reflect.Method.invoke(Method.java:324)
         org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:284)
         java.security.AccessController.doPrivileged(Native Method)
         javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
         org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:306)
         org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:200)

    This is a known issue.
    Here's an explanation of the behaviour you are seeing:
    The misleading error message is printed only in the case where a javac
    compilation error line number cannot be mapped back to a line number
    in the JSP source code.
    The internal representation of a JSP element ("JSP node") in the JSP compiler
    contains the following info:
    - The begin line number of the JSP element in the JSP page
    - The begin and end line numbers ("range") of the Java code that was
    generated for the JSP element
    When attempting to map a javac error line number back to the JSP
    source line, we determine the range into which the javac error line
    number falls, and retrieve the JSP source number of the JSP element
    associated with that range.
    However, in some cases, it is impossible to trace a javac error line
    number back to the JSP element that caused the error. For example,
    consider the following scriptlet:
    <%
    String query = request.getParameter("query");
    if(query != null) {
    out.println(query);
    } else {
    out.println("(null)");
    // } // <-- !Missing brace syntax error
    %>
    Since the JSP compiler wraps the generated code into a
    try-catch-finally block, the above syntax error in the scriptlet
    causes havoc with that try-catch-finally block, and results in 3 javac
    errors:
    <file>jsp.java:<line1>: 'catch' without 'try'
    } catch (Throwable t) {
    ^
    <file>jsp.java:<line2>: 'try' without 'catch' or 'finally'
    try {
    ^
    <file>jsp.java:<line3>: '}' expected
    Notice that all of the above javac error numbers are outside the range
    of the java line numbers corresponding to the scriptlet that caused the
    error, and therefore cannot be mapped back to any line numbers in the
    JSP page source.
    AS 8.0 PE does not handle this case correctly, and prints out the
    misleading error message (though the real error message can be found
    in the server log).
    Notice that this problem is going to be fixed in AS 8.1, so that if a
    javac error line number cannot be mapped back to a JSP page line
    number, the javac error is still returned to the client.
    In AS 8.0 PE, you need to check your server log to find out why the compilation failed.
    If you still have any problems, send me your JSP, and I will take a look at it.
    Thanks,
    Jan

  • How to run a background process in a J2EE App ?

    Hi guys,
    Here is the requirement which totally stumped me.
    " The web app should have a feature like a background process or something like cron jobs.. which keeps on running in the background and at a particular time each day calls a method". User intervention is not an option.
    Now had this been a stand alone app .. I could have done this using Threads.. but i cant possibly use threads in a J2EE app. Any pointers.. how I can go about realizing this
    Thanks for your replies.
    Cheers!

    You could take the approach that SoulTech mentioned and spawn a new thread from the Servlet's init method. To have the servlet invoke this method with no intervention, you would need to set the following parameter in your servlet definition in your web.xml:
    <servlet>
      <servlet-name>MyStartupServlet</servlet-name>
      <servlet-class>com.my.company.MyStartupServlet</servlet-class>
      *<load-on-startup>1</load-on-startup>*
    </servlet>When you deploy your application, the servlet will be loaded, and its init method will be called.
    If your application is running in a servlet container, I believe you are allowed (by the specification) to spawn your own threads, but you should do so carefully. Since you're writing a scheduler and not some kind of worker threads that are messing with your database, I think you should be okay. Still, just to keep it clean you should add any clean-up logic you may need to your servlet's destroy method. I know that in an EJB container, spawning your own threads can definitely be a problem and the container makes no guarantees that they will function correctly. The J2SE Timer class could be used if you're not using EJB, but the Timer class doesn't have support for J2EE - that's at least part of what led to the introduction of the timer beans in J2EE 1.4. If you're already using EJB, especially EJB 3.0, then the timer service provides a convenient built-in mechanism to do exactly what you want.
    There are always multiple ways to solve any problem...
    Edited by: proflux on May 15, 2008 1:04 PM

  • J2EE App Servers

    Hi
    I am currently investigating the setup we'll need to develop java apps - we're looking to develop multi-tier applications using jsp,servlets and ejb's. We are however currently tied into using Microsoft IIS webservers. From what I can gather we therefore have no choice but to purchase an (expensive) J2EE App Server to handle the jsp, servlet and ejb's - like Borland's AppServer 4.5 both for development and deployment of our final application to our customers (assuming they want to host the application themselves).... Does anyone know of some less expensive options to handle this kind of Java development or can someone suggest an alternative architecture?
    Many thanks.

    As some has said before there is a free app server for J2EE based applications, and you can find it at:
    http://www.jboss.org/
    As for web server you can use the Tomcat which is also free.

  • Usage of Object Cache for Java in J2EE apps

    Hi,
    we are investigating on whether we can use the Object Cache for Java
    (OCS4J) for our requirements. The question we have come across is:
    What is the designated way of integration for the Object cache to fit
    into the J2EE environment? Unfortunately, although the current manuals
    group OCS4J into the "Oracle Containers for J2EE Services Guide" and the
    suggested package name for the whole thing in JSR 107 seems to be
    javax.util.jcache, there is very little documentation on how the
    designers would like J2EE programmers to use the cache from within a
    J2EE app and all examples given are not from within a J2EE environment.
    We are in particular thinking about a hierarchy of several cache
    "compartments" (Region->Subregion->group) for different topics and using
    the hierarchical name of the cache (region.subregion.group) as the
    primary key for BMP Entity beans, each of them having their own
    CacheAccess object. Then we would have an API of stateless Session beans
    on top of that, which would be determining the cache "compartment", get
    the appropriate Entity Bean with the Cache Access object and then do the
    required operations on the cache.
    But then we immediately run into the question of how the mapping between
    Cache Objects and CacheAccess objects will be done etc.
    So is there anybody that can give us any hints how to use the OCS4J in
    an EJB scenario?
    Thanks in advance for any help!
    Andreas Loew
    [email protected]

    We have Java client requesting over HTTP to application server. We would like to cache some of the objects created by the servlet while serving the request. Can I use the OCS4J for caching the Java objects. Do I require any software or just copying the JAR file and importing the class would serve the purpose?
    Regards
    Arun

  • Project Conventions for J2EE Apps Early Access...

    Hi
    I am trying to set up a standardized directory structure for J2EE apps that is flexible enough from a simple webapp to a complex J2EE App with multiple EJB components, WARs...etc..etc...
    For this, I turned to Java Blueprints Guidelines, Project Conventions for Enterprise Applications Early Access 1 posted on the Sun's web site...
    This document states among follwoing that (quote)
    -----(quote)
    These conventions, which the Java BluePrints team has followed with its applications (which can be accessed from http://java.sun.com/blueprints/code/index.html), assume that developers use the Ant tool for building projects. Developers using other build tools may have to make slight modifications to the conventions.
    ----(end quote)
    I have downloaded the latest J2EE SDk which has samples directory containing the famous , Adventure BUilder, Petstore, etc, etc.....But they do not follow project directory structure as outlined in this document...Moreover, I found each app has different project directory structure even for the same functional part..
    1. Are the J2EE sample apps bundeled with J2EE SDK different than the ones available as separate download?
    2. If they are not, where can I download sample apps that demonstrate project conventions outlined in the guidelines document...
    Any comments are welcome...
    Thanks
    zambak

    Hi,
    The project conventions are new and early access version1. So it will be changing a little bit and as a result the apps may get a little out of sync. We are currently switching the apps over to match with the project conventions. For an app that dempnstrates project conventions, please see the adventure builder on java.net at https://adventurebuilder.dev.java.net/
    We are working on a revised version of the project conventions, so your feedback/comments would be highly appreciated.
    -Smitha
    Hi
    I am trying to set up a standardized directory
    structure for J2EE apps that is flexible enough from a
    simple webapp to a complex J2EE App with multiple EJB
    components, WARs...etc..etc...
    For this, I turned to Java Blueprints Guidelines,
    Project Conventions for Enterprise Applications Early
    Access 1 posted on the Sun's web site...
    This document states among follwoing that (quote)
    -----(quote)
    These conventions, which the Java BluePrints team has
    followed with its applications (which can be accessed
    from http://java.sun.com/blueprints/code/index.html),
    assume that developers use the Ant tool for building
    projects. Developers using other build tools may have
    to make slight modifications to the conventions.
    ----(end quote)
    I have downloaded the latest J2EE SDk which has
    samples directory containing the famous , Adventure
    BUilder, Petstore, etc, etc.....But they do not
    follow project directory structure as outlined in this
    document...Moreover, I found each app has
    different project directory structure even for the
    same functional part..
    1. Are the J2EE sample apps bundeled with J2EE SDK
    different than the ones available as separate
    download?
    2. If they are not, where can I download sample apps
    that demonstrate project conventions outlined in the
    guidelines document...
    Any comments are welcome...
    Thanks
    zambak

  • Using JNDI to access config file located outsite j2ee app

    Hi I'm wanting to store a config file for my J2ee app, somewhere on a tomcat server possibly inside the
    conf/ directory so that I can update this config file without having to redeploy the j2ee app every time a change is made.
    I've been told I can use JNDI to access this file, but I can't seem to find any examples or documentation on how I can do this.
    I'm new to JNDI and would appreciate any help, or suggestions.
    Thanks,
    Tim
    EDIT:
    So far I can access the file with this code:
    Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.fscontext.RefFSContextFactory");
              try {
                   Context ctx = new InitialContext(prop);
                   // look up context for name
                   //env.put(Context.PROVIDER_URL, "file:C:\\confluence\\confluence-2.5.1-std\\conf");
                   File f = (File)ctx.lookup("/confluence/confluence-2.5.1-std/conf/test.txt");My new problems are:
    1. The commented line env.put(Context.PROVIDER_URL, "file:C:\\confluence\\confluence-2.5.1-std\\conf"); it says in examples that this should set the dir to look in to the conf dir but if i change the lookup value to just test.txt it cannot find it.
    2. Can I somehow set the context to look into the conf directory of Tomcat without hard coding the path, as the path could change or be different on different machines??
    Edited by: Timothyja on Jan 15, 2008 7:00 PM

    Hi Kiran,
    Looking at the code you sent and the error, it looks like you should be casting the ds object to a javax.sql.DataSource object not a weblogic.jdbc.common.internal.RmiDataSource object.
    You may find some useful info at the following URL:
    http://edocs.bea.com/wls/docs81/jdbc/rmidriver.html#1026007

  • Building and deploying J2EE apps ?  Now there is a solution for production root cause analysis.

    Is your organization building and deploying J2EE apps? If so, Halo
    can help solve one of the toughest issues facing enterprises today:
    Finding the root cause of software faults.
    "Halo monitors, pinpoints, reports on and provides a source-code level
    root cause of software faults in deployed J2EE apps. Halo is unique
    because it's the only technology that can give you a root cause
    diagnosis in a fully deployed, live production application. Halo has
    such low performance overhead that customers deploy their final,
    production versions of their applications with Halo enabled.
    Used with Web Application Servers like WebLogic, Halo helps ensure
    that deployed code is reliable and able to be quickly fixed if
    problems turn up. Most important, because Halo is an "always on"
    technology, you get all the information you need to rapidly solve a
    problem on the first fault. Problem replication and bug reports are
    obsolete with Halo
    "Halo has a unique ability to provide a root cause diagonosis and
    understanding
    of software problems in production systems, without needing to
    replicate the
    issue.
    Test on WebLogic proved that Halo runs with extremely low overhead and
    is suitable for use in deployed production systems"
    Andrew Sliwkowski, Software Engineer
    BEA Systems, Inc.
    The key is Halo's high performance, low overhead TraceBack
    instrumentation technology. Based on technology out of MIT and proven
    in the field, TraceBack enables you to instrument JARs, EARs and WARs
    within minutes, without touching source code.
    Halo is useful throughout the entire application life cycle, from
    development through test, beta and deployment.
    If you have interest in learning more visit our website at
    www.incer.com or email me directly at [email protected] (Rick Martin)

    I have two questions. We have just started developing apps using jdev9i, 9iAS v2 and are new to the j2ee environment so my questions may be very easy ones.
    Question 1: We have set up Oracle pooling connection to our databases. We have a development, test and production database. When I deploy my application, it includes the connections. This is preventing me from moving the EAR files from dev to test to prod without modification and re deploying to my EAR file. Is there a way or a place that I can put my database connections that will not be included in my EAR files and the application still find them?datasources.xml is where the info regradings connection to databases is licated. If you're using 9iAS
    you can use EM to create datasource entry at the global level. In OC4J standalone you could use admin.jar
    or edit the file. Check out the standalone user's guide at http://otn.oracle.com/tech/java/oc4j/pdf/oc4j_so_usersguide_r2.pdf.
    Also, you will othe OC4J docs on OTN.
    Question 2: I have a stand alone oc4j set up for our developers to use while testing their applications. The applications include libraries supplied in jdev such as xml parser v2. I do not want to deploy those lib files with the app because I will have to redeploy all my apps if I upgrade jdev. I just want to be able to upgrade the libraries, test the apps and not have to redeploy everything. I can do this by coping the jdev lib to 9iAS but I can't seem to find the right place to put the lib for the stand alone oc4j instance. You can use the library tag within application.xml for server wide availability. Check out the article
    http://otn.oracle.com/oramag/oracle/02-sep/o52oc4j_2.html specifically class loading in OC4J section
    Any help would be greatly appreciated. Thanks in advance.

  • How to read weblogic user/password within a J2EE app ?

    All,
         There is an J2EE that exposes a webservice and the service can not be secured with ws-security since the service is an exact implementation of an standard that does not mandate  ws-secutiry and only insists on SSL/TLS. The application however needs a legitimate authenticated weblogic user for the rest of its work and hence the app has to read a known user created in the weblogic and then read its password as well and authenticate  within the app and use that authenticated subject. User can create this predefined user in weblogic and we may ask user to store the same weblogic password also in a CSF like OPSS and then have the app read the CSF, but since the password is available in the weblogic internal ldap, we want to leverage that and read the user's password using any of the weblogic mbean's APIs. Can anyone provide a pointer on how to read a user's password within the Weblogic's embedded ldap ?
         We referred to this Developing with the User and Role API - 11g Release 1 (11.1.1) & 6 Managing Security Realms with JMX but could not successfully get it working with J2EE app (Servlet/Filter).

    You can use JMX
    Please find a sample here
    List Users and Groups in Weblogic using JMX | Middleware wonders!!

  • Concurrent Deployment of Multiple Releases of a J2EE App to WLS 7.0

    Is it possible to concurrently deploy multiple releases of the same
    J2EE app to WLS? If so, what was the process and your experience with
    it?

    Is it possible to concurrently deploy multiple releases of the same
    J2EE app to WLS? If so, what was the process and your experience with
    it?

  • J2EE App Server with virtual servers

    H! !
    I have a Win2K with J2EE App Server 1.4. Everything is working fine. In this computer I stopped the IIS 5.0 in order to use the HTTP Server included with the product.
    I also run the DNS on the same machine with 3 domains. All name resolutions for these 3 domains work fine.
    Now I want to enter to any of the 3 domains freelyand execute JSP apps. But I don't want to enter ports numbers like this:
    http://www.mytest.com:8081/hello.jsp
    I just want to enter:
    http://www.mytest.com/hello.jsp
    So I defined a new http-port listener pointing to the 80 port on this server. With no SSL support.
    Name: http-port80
    IP Address: 0.0.0.0
    POrt: : 80
    Return server name: <blank> (Should I put here the name of the computer?)
    Then I defined a new virtual server using the http-port listener. I set the following fields:
    ID: mytest
    Hosts: www.mytest.com (Should I put here the name of the computer?)
    HTTP Listener: http-port80 (This is the name of the port listener)
    Everything seems to be fine. I can enter http://www.mytest.com and call the hello.jsp it's ok.
    But then I create a new virtual server for http://www.mytest2.com exactly as the one for the www.mytest.com, except for the host field: http://www.mytest2.com
    Then when I restart the app server I got the message on the log: "Port already in use".
    I want to use the same http-listener because I don't want to enter http://www.mytest2.com:<port>
    Any ideas how to handle this?
    Am I doing something wrong on the configuration?
    Thank you very much!!

    What I want is to enter to any of the 3 domains freely and execute JSP apps. But I don't want to enter ports numbers like this:
    http://www.mytest.com:8081/hello.jsp
    I just want to enter:
    http://www.mytest.com/hello.jsp
    As far as I understand only by having an http-listener linked to the virtual web server I can achieve this goal, right? Or Am I on the wrong direction?

  • How To Install J2EE app to ColdFusion's Tomcat Server

    Our client has purchased IBM Analytics, that they want to run with the ColdFusion servers. IBM has given over the EAR files to deploy on Tomcat. But, ColdFusion uses a highly modified Tomcat. How would someone deploy another J2EE app in this scenario, without installing another server?

    Hi,
    Thank you for your post. Please refer to http://help.adobe.com/en_US/ColdFusion/10.0/Installing/WSc3ff6d0ea77859461172e0811cdec18c2 8-7fda.html for J2EE deployment.
    Regards,
    Anit Kumar

Maybe you are looking for