How to get servlet container name on which servlet is running

I tried getServletInfo(),but I couldn't get the information. Please give me code to find the servlet container on which servlet is running.
Is there any system property which will retrieve servlet container information such as its name and version
Thanks & Regards,
Nasrin.N

getServerInfo() should work.
What about getServerInfo() doesn't work for you?
My standard solution is to this in a JSP page:
<h2> Server Info </h2>
Server info = <%= application.getServerInfo() %> <br>
Servlet engine version = <%=  application.getMajorVersion() %>.<%= application.getMinorVersion() %><br>
Java version = <%= System.getProperty("java.vm.version") %><br>Cheers,
evnafets

Similar Messages

  • How to get the role name in which query is published ?

    Hi Experts,
       Is there any table where i can get the name of the role in which a particular query is published. I know that if i have a role , i can check in pfcg giving that role name and in menu tab i can see all the queries published under that role. But if i know query but not role how to get the role name . Is there any table or functon modules or programs to get the information.
    Thanks & Regards
    Vamsi Kiran

    Check this table
    AGR_HIER

  • How to get JSP file name within a servlet?

    I wonder is there any method that we could use to print out the JSP's file name which called a servlet within the servlet itself? For instance, A.jsp called B.class which is a servlet, and when the servlet is being invoked print out "A.jsp" or "A" in a dos screen.
    Thanks for any reply.

    The Referer is an optional HTTP header, and it only exists when a page is called from an hyperlink (i.e. from another web page). The general meaning of Referer is the "caller page". There at least two situations in which there will be no Referer header:
    1. When the usuer types in the destination page address directly, or get it from a bookmark/favorite or similar. Since there is no caller page, there would be no Referer.
    2. Althought browsers usually send the referal page when you choose a link, some privacy control programs (such as Norton Internet Security etc.) can intercept the request and strip out the Referer header, even when there is a caller page.

  • How to get the server name/hostname on which JVM is running?

    How to get the server name/hostname on which JVM is running from the Servlet or normal class?

    InetAddress.getLocalHost()

  • How to get the Application name/fullpath in a servlet deployed in WebLogic

    Hi ,
    Just like we can get the domain root directory from weblogic.management.DomainDir
    String root = DomainDir.getRootDir() ;and domain name from weblogic.management.configuration.DomainMBean
    DomainMBean domainMBean = MBeanUtils.getDomainMBean();
    String domainName = domainMBean.getName() ;How can i get , the application name in which the servlet is deployed from inside the same servlet ? Which API from weblogic provides that information ?
    for eg : application path = Middleware/user_projects/domains/Domain_1/servers/AdminServer/upload/webapp1.war
    and application name = webapp1.war
    Edited by: Tom on Mar 31, 2011 9:32 PM

    Not sure about Weblogic Specific API however you can use Java API.
    public void init(ServletConfig config) throws ServletException {
              // TODO Auto-generated method stub
              System.out.println(config.getServletContext().getRealPath(""));
              System.out.println(config.getServletContext().getContextPath());
    output:
    C:\Documents and Settings\user\KEDB\KEDBRISKIT\WebContent --- Application Path
    /KEDBRISKIT --- Application Name
    -Akshay

  • How to get the specific name of the workset which is currently selected by the user in sap portal 7.0

    Dear Expert,
    I have one requirement like to read the selected workset name in portal by the current user.I have read two documents regarding how to retrieve the PCD contents (iViews, Pages, Worksets and Roles) and its properties like Created by, Changed by, Last changed by and others using PCD API.
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/6112ecb7-0a01-0010-ef90-941c70c9e401?overridelayout=true
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/508baf88-9335-2d10-efa6-c6ad61e5fc4b?quicklink=index&overridelayout=true
    But I am not able to understand how to get the specific name of the workset which is currently selected by the user.Can you please help me.
    I am using portal 7.0.
    Thanks & Regards,
    Patralekha

    Hi Expert,
    I found that we can use Interface INavigationHelperService to read Portal Role selected by user at runtime from http://scn.sap.com/thread/52194
    But this class is available in SAP NetWeaver 7.30 Enterprise Portal .
    But in SAP NetWeaver 7.0 Enterprise Portal that interface is not available.
    INavigationService is available there.
    But didn't get any proper discussion on this interface for the same requirement.
    Can you please help me.
    Thanks & Regards,
    Patralekha

  • How to get the form name which is used in standard tcode like me23n in sap

    how to get the form name which is used in standard tcode like me23n in sap
    Moderator message: four out of four threads locked, please read and understand the following before posting further:
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|Asking Good Questions in the SCN Discussion Spaces will help you get Good Answers]
    Edited by: Thomas Zloch on Nov 18, 2011 1:32 PM

    how to get the form name which is used in standard tcode like me23n in sap
    Moderator message: four out of four threads locked, please read and understand the following before posting further:
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|Asking Good Questions in the SCN Discussion Spaces will help you get Good Answers]
    Edited by: Thomas Zloch on Nov 18, 2011 1:32 PM

  • How to get list of applied patches which applied using admrgpch

    How to get list of applied patches which applied using admrgpch

    You can't really get the individual patch IDs from a merged patch, unless you have the log file from the admrgpch run available.
    You can, however, get the list of bugs fixed by a merged patch, and those bug numbers sometimes, but not always, correspond to a patch ID. Keep in mind, though, that individual patches often contain entries for multiple bug numbers.
    Here's a query that I use to look at the contents of merged patches. It works best if the merged patches have been given unique names, instead of the default name 'merged' from admrgpch. If you run it and see that everything belongs to patch name 'merged,' you might want to change the selected column to ap.applied_patch_id instead of ap.patch_name.
    select ap.patch_name
    , ad.orig_patch_name
    , ad.driver_file_name
    , ad.merged_driver_flag
    , ad.merge_date
    , bug.bug_number
    , cp.patch_abstract
    from ad_applied_patches ap
    join ad_patch_drivers ad using (applied_patch_id)
    join ad_comprising_patches cp using (patch_driver_id)
    join ad_bugs bug using (bug_id)
    order by applied_patch_id;
    Regards,
    John P.
    http://only4left.jpiwowar.com

  • How to get the VARIANT name in the program

    Hi Guys,
    Can somebody tell me how to get  the VARIANT name in a program.
    I have to perform some code with specific variant only. So I want to check in program which variant has been used to call the program.
    Thanks,

    Hi,
    Variants are stored in table VARI and VARID.
    You can use RS_ALL_VARIANTS_4_1_REPORT to get all the variants for a report program.
    please check out the link below it will be helpful to you
    Re: Programs for a transaction variant
    Hope this helps.
    ashish

  • How to get the function name/ID  of the current page

    HI,
    I searched the forum and google, but it is not clear on how to get the function name of the current page.
    I have 4 functions in my self service A ,B,C,D (seeded page links ) they all have to go to a page called hhhPG. Based on which function user is clicks I have to show the data in hhhPG.
    so my question is how to get the function name ? I mean I need to know if user click on link A , B, C or D link and came to this page.
    I found below in one forum and also there is getfunctionID in pageContext , but I do not know what to pass to getfunctionid("???") to get value.
    FunctionSecurity funcSecurity = pageContext.getFunctionSecurity();
    Or is there a better way of know where user is coming from ? like geturl....
    Please help, I need this ASAP.
    Thank you.

    Use below to find out how the user came into the page
    FunctionSecurity funcSecurity = pageContext.getFunctionSecurity();
    boolean isFunc1 = funcSecurity.testFunction(funcSecurity.getFunction("YOUR_FUNCTION_SHORT_NAME1"));
    boolean isFunc2 = funcSecurity.testFunction(funcSecurity.getFunction("YOUR_FUNCTION_SHORT_NAME2"));
    boolean isFunc3 = funcSecurity.testFunction(funcSecurity.getFunction("YOUR_FUNCTION_SHORT_NAME3"));
    boolean isFunc4 = funcSecurity.testFunction(funcSecurity.getFunction("YOUR_FUNCTION_SHORT_NAME4"));
    So one of them will be true based on the function the user came in.
    Write your logic based on these flags.
    Regards,
    Peddi.

  • In Mac how to get the Full name of a file Programmatically?

    Hi Friends,
             I am doing one Mac application for displaying the contents of a file. I can able to get some information about the file by using this code below...
      NSDictionary *dict=[fileManager attributesOfItemAtPath:myPath error:nil];
    Now I want to get the some other informations also like Full Name, copyRight, version... So Please suggest me how to get the full name of a file Programmaticallly?

    Your question doesn't make sense.
    First off, if you are going to get the attributes of a file, you need its full name before you can do anything. So that's part one taken care of.
    This function returns a dictionary full of typical file information (type, size, mod dates, etc.) as well as some HFS data (creator code, type code) which, I strongly suspect, are not "pulled out of the file" but rather generated on the spot. (See NSFileManager for the full list of attribute keys.)
    The other items you hoped of retrieving are not part of the regular file system. Sure, a Truetype font has a copyright string and a version, but what about an HTML file? A PNG? A text file you just created?
    There simply are no standard functions to retrieve copyright and version.

  • IDM : How to get the Resource name in Exclude Rule during Reconciliation?

    Hi
    Problem Statement => How to get the Resource name in Exclude Rule during Reconciliation.
    Problem Description => Apparently, we use exclude rule for not consider some account during reconciliation.
    I need the resource name in exculde rule during reconciliation. I tried with getResources() method which is an inbuilt method.But it gives all the resources are aviablable in the repository (IDM). I need only the current reconcilied resource name instead of fetching all the resouce.
    Can any one please help how to get the resource name in exclude rule during reconciliation?
    Thanks in advance for you help.
    Thanks,
    Chellappan

    Hi,
    Thanks for your reply.
    I have 50 resouces and these resouces using the same kind of exclude rules. In the exclude rule, i am using resource name to do some work. If i get the resouce name in exclude rule, then i can use the same exculde rule for 50 resources. This will minimise the rule count from 50 to 1. For that, i need resouce name.
    Thanks,
    Chellappan Sampath.

  • How to get mobile model name for different types mobile devices

    Hi,
    I have checked few thread in this forum about getting mobile model name at server. So far, i noticed the mobile name is set manually in the midlet as user-agent .
    HttpConnection connection = null;           connection = (HttpConnection)Connector.open(url);          connection.setRequestMethod(HttpConnection.POST);          connection.setRequestProperty("User-Agent","Nokia7110 Profile/MIDP-1.0 Configuration/CLDC-1.0");
    i retrieve the header information from servlet like below :-
    String userAgent = request.getHeader("User-Agent");
    How to get mobile model name for different model devices , not by manually adding the model name in midlet?
    Thanks in advance :-)

    Hi,
    In J2ME there is no method to get the model number from the device. how ever you can use the APIs provided by the device manufacturer if available. But still the APIs will not work with devices from other manufacturer or sometimes it will not work with the devices of the same manufacturer if the API is not supported. so it is better to send the device model name through the header.

  • Can we get the porlet name of which the JSP file is resided ?

    Hi all,
    Can we get the portlet name of which the JSP file is resided?
    Sincerely,
    Alan.

    you could try the following code
    <%@ page import="com.bea.portal.model.Portlet"%>
    <%@ page import="com.bea.portal.model.PortletState"%>
    <%@ page import="com.bea.portal.render.servlets.jsp.PortletRenderHelper"%>
    PortletState portletState = PortletRenderHelper.getPortletState( request);
    String portletName = portletState.getDisplayName();
    "Alan Liu" <[email protected]> wrote:
    Hi all,
    Can we get the portlet name of which the JSP file is resided?
    Sincerely,
    Alan.

  • How to get a computer name in teststand step ?

    how to get a computer name in teststand step ?

    Hi,
    Use an ActiveX Automation Adapter with the following settings,
    ActiveX Reference : RunState.Engine
    Automation Server: TestStand API (depends on your version)
    Object Class: Engine (IEngine)
    Action: Get Property
    Property: ComputerName
    Then set your Parameters: to pickup the String ComputerName.
    Regards
    Ray Farmer
    Regards
    Ray Farmer

Maybe you are looking for

  • Ram Upgrade on Satellite P500 - from 4GB to 6 GB

    I get the feeling that I'm asking a stupid question but here goes. Just bought a P500 with 4Gb memory and decided to go with the recommended 2Gb upgrade. Went to install the ram chip and could only find 2 slots both of which are occupied with the exi

  • HTTP Listeners shown as running but can't stop, start or configure

    In 4.0.8.2 Oracle Application Server Manager Enterprise Edition, HTTP Listeners, for the "www", the listener shows as down but is actually running. If I try to stop it, it says it is not running (the IE dialog box pops-up). If I try to start it, it s

  • My Blackberry 8100 is a teapot!

    Went to sync my Blackberry 8100 last night when I had popup saying there was an update for my Blackberry to V4.5. My total involvement with the process was to press the 'next' button. I went to check on dinner and when I returned there was a message

  • Binding done at variable declaration

    What is difference between     int x;     x=5; and int x=5; What are different binding takes place? How Binding differs in both the cases? Can anybody please tell me about it.

  • Optimal outline order for Hyperion Reporting

    Good Morning - What is the best outline order for faster report retrieval ? I am not referring to optimal order for calculation which is modified hour glass. Is it still inverse order of hour-glass? Thanks