Any way to get number of active sessions

Hi,
          With the deprecation of the HttpSessionContext interface as of Servlet API
          2.1 for security reasons, is there any way to know how many sessions are
          currently active in a given WebLogic instance?
          Thanks,
          Sanjiv
          

You could make it a singleton. The overhead is nothing ... trust me. Run
          WebLogic through a profiler if you don't ;-)
          Good luck,
          Cameron Purdy, LiveWater
          "Sanjiv Gulati" <[email protected]> wrote in message
          news:[email protected]...
          > Thanks for sharing this technique. Although I haven't used the
          > HttpSessionBindingListener interface myself, this will work as long as I
          add
          > an instance of SessionCounter in each new session. The only modifications
          > I'll add to the code below would be a synchronized block within the
          > valueBound and valueUnbound methods so that modifications to m_cSessions
          are
          > thread safe.
          >
          > The overhead associated with this approach will be the following:
          > 1) For every session there will be an associated SessionCounter, and
          > 2) Serialization of requests that end up invoking the valueBound &
          > valueUnbound methods.
          >
          > But I guess this cannot be avoided.
          >
          > Thanks,
          > Sanjiv
          >
          > Cameron Purdy <[email protected]> wrote in message
          > news:[email protected]...
          > > The only portable implementation is to have all requests go through your
          > > servlet code (or JSP code) and check if the session is new
          > > (HttpSession.isNew). If so, register a value with the session that
          > > implements HttpSessionBindingListener. Something like:
          > >
          > > class SessionCounter implements HttpSessionBindingListener {
          > > // count of active sessions
          > > private static int m_cSessions;
          > > // accessor for count of active sessions
          > > public int getSessionCount() {
          > > return m_cSessions;
          > > }
          > > // this object placed on a session
          > > void valueBound(...) {
          > > ++m_cSessions;
          > > }
          > > // this object removed from a session
          > > void valueUnound(...) {
          > > --m_cSessions;
          > > }
          > > // end class
          > > }
          > >
          > > It is host-local ... meaning it only tracks one host in a cluster.
          > > Actually, it only tracks sessions within one classloader on one host in
          a
          > > cluster, but don't worry about that distinction.
          > >
          > > And no, I've never done it, but it is apparent that you could, if you
          > chose
          > > to:
          > >
          > > 1) Count sessions
          > > 2) Track all session instances
          > > 3) Have session-level events, such as onCreate/onDestroy
          > >
          > > Hope it helps,
          > >
          > > Cameron Purdy, LiveWater
          > >
          > > "Sanjiv Gulati" <[email protected]> wrote in message
          > > news:[email protected]...
          > > > Hi,
          > > >
          > > > With the deprecation of the HttpSessionContext interface as of Servlet
          > API
          > > > 2.1 for security reasons, is there any way to know how many sessions
          are
          > > > currently active in a given WebLogic instance?
          > > >
          > > > Thanks,
          > > > Sanjiv
          > > >
          > > >
          > >
          > >
          >
          >
          

Similar Messages

  • Is there any way of getting back from a wrong clicked free trial to add my serial number correctly?

    Hi
    On purchasing a new imac I copied the apps across & on opening CS6 was requested to load serial numbers, through tiredness I added the seria; number from CS5.5 and therefore not recognised for the CS6, then when about to enter again through tiredness I must have clicked free trial and now have the CS6 in that format.
    Is there any way of getting back to that initial box to load the correct numbers & get out of trial as although it works I need it set up correctly?
    Any help appreciated

    Sorry, cant see this visible on menu or drop downs, did run through all menus before posting, could just be tired from 3 weeks straight.
    If this is not an option does that mean I am set up ?

  • When closing multiple tabs, is there any way to get back the option of saving those tabs OR NOT for your next session, within the warning dialogue box itself?

    For brief period of time, not in FF4, there was the option whereby when I closed multiple tabs, a firefox dialogue box opened warning me that I'm about to close multiple tabs, '''AND ALSO''' asking me if wanted to save those tabs for my next session, or trash them.
    The primary issue IS NOT about saving tabs. The primary question here is about getting THE OPTION back to the CLOSING MULTIPLE TABS WARNING DIALOGUE.
    The use case here should be obvious. However, since it is clearly not obvious that different people work in a variety of ways, and neither of those methods of working is "wrong" or "right" I will elaborate: Some people, for whatever reason, it doesn't matter why, want to save all their tabs on some occasions, and on other occasions don't.
    This preference varies throughout the day. Therefore it is inefficient to constantly go to preferences and change whether or not I want firefox to open all my tabs from my last session. It is more LOGICAL to place an option in the multiple tab warning dialogue as well, for people whose preference constantly changes.
    This option was available for a time in most of the Firefox 3 versions. Is there any way to get back this option in Firefox 4?

    Firefox 4 saves the previous session automatically, so there is no need for asking if you want to save the current session.
    You can use "Firefox > History > Restore Previous Session" to get the previous session.<br />
    There is also a "Restore Previous Session" button on the default <b>about:home</b> Home page.
    You can set the warn prefs on the <b>about:config</b> page to <b>true</b> via the right-click context menu or toggle the value with a double left-click.
    * browser.showQuitWarning, see http://blog.zpao.com/post/3174360617/about-that-quit-dialog
    * browser.tabs.warnOnClose, see http://kb.mozillazine.org/About%3Aconfig_entries
    * browser.warnOnQuit , see http://kb.mozillazine.org/browser.warnOnQuit
    * browser.warnOnRestart , see http://kb.mozillazine.org/browser.warnOnRestart
    To open the <i>about:config</i> page, type <b>about:config</b> in the location (address) bar and press the "<i>Enter</i>" key, just like you type the url of a website to open a website.<br />
    If you see a warning then you can confirm that you want to access that page.<br />

  • Is there any way to get Session

    Hi All,
    Is there any way of getting the HttpSession object reference using sessionid?
    thanks in advance
    Raghu

    Only by looping over all the sessions and comparing
    the id to the id you wantHow do you get all the sessions collection?

  • In addition to the FormsCentral subscription charge ($152.87 including tax) I was billed about the same time for $15.93. I can't find any way to get in touch with anyone from Adobe. The phone number I'm supposed to call is cut off on my invoice. Can someo

    In addition to the FormsCentral subscription charge ($152.87 including tax) I was billed about the same time for $15.93. I can't find any way to get in touch with anyone from Adobe. The phone number I'm supposed to call is cut off on my invoice. Can someone respond ASAP? Thanks

    I have forwarded your request to the support team that should be able to resolve this issue for you quickly. Expect to hear from them shortly.
    Andrew

  • Are there any ways to get sequence number other than getting it for each re

    are there any ways to get sequence number other than getting it for each record

    CACHE is the number of values Oracle stores in memory. So the first call to NEXTVAL Oracle grabs x numbers; subsequent calls to NEXTVAL are served from memory until they're all gone and them another bunch is grabbed. The attached sql*plus output demonstrates this behaviour.
    Note that normally unused numbers in the cache are returned to the data dictionary but in exceptional circumstances (DB crash) they may be lost.
    Cheers, APC
    SQL> create sequence seq cache 3
      2  /
    Sequence created.
    SQL> select last_number from user_sequences
      2  where sequence_name = 'SEQ'
      3  /
    LAST_NUMBER
              1
    SQL> select seq.nextval from dual
      2  /
       NEXTVAL
             1
    SQL> select last_number from user_sequences
      2  where sequence_name = 'SEQ'
      3  /
    LAST_NUMBER
              4
    SQL> select seq.nextval from dual
      2  /
       NEXTVAL
             2
    SQL> select last_number from user_sequences
      2  where sequence_name = 'SEQ'
      3  /
    LAST_NUMBER
              4
    SQL> select seq.nextval from dual
      2  /
       NEXTVAL
             3
    SQL> select last_number from user_sequences
      2  where sequence_name = 'SEQ'
      3  /
    LAST_NUMBER
              4
    SQL> select seq.nextval from dual
      2  /
       NEXTVAL
             4
    SQL> select last_number from user_sequences
      2  where sequence_name = 'SEQ'
      3  /
    LAST_NUMBER
              7
    SQL>

  • As soon as I activated my iCloud on my iphone and merged the calendar, lost all the content of my calendar. Is there any way to get it back?

    lost all the contents of my calendar on my iphone after activation of iCloud. Is there any way to get it back?

    Restore it from your most recent backup or from the computer Calendar app you sync your iPhone with via iTunes.

  • HT2357 I accidently deleted all of my updates and they're not coming back. Is there any quick way to get these updates active again?

    I accidentally deleted all of my updates and they're not coming back. I haven't been able to make any updates since 2006. I have a log of my past updates but I cannot seem to get them active again. Is there any easy way to get these updates active again?
    This was a while ago back in 2006 but from what I can remember I actually deleted/permanently removed these updates from my list of updates. I tried keeping all the updates except for two that I did not need and somehow deleted all of the updates I wanted to keep. I've tried reseting my ignored updates but that does not bring back the updates. If i delete the two that I originally attempted to remove - it only brings those two back. I hope there is still some way to get these updates back. I appreciate any help that anyone is able to give me.
    Thanks!
    Plum<3

    10.4.11 is the latest version of 10.4.
    The security updates for 10.4 are listed here:
    http://support.apple.com/kb/HT5165
    If you are interested in updating to 10.5, see this tip.

  • I've lost my iPhone 4... How can I find it when the device is offline when using "find my iPhone app"????? Any way of getting a location from it????

    I've lost my iPhone 4... How can I find it when the device is off linesmen using "find my iPhone app"????? Any way of getting a location from it?????

    No. It must be online in order to locate it.
    What To Do If Your iDevice Is Lost Or Stolen
    iPhone, iPod Touch, and iPad
    If you activated Find My Phone before it was lost or stolen, you can track it only if it is connected to the Internet by Wi-Fi or cellular. What you cannot do is track your device using a serial number or other identifying number. You cannot expect Apple or anyone else to find your device for you. You cannot recover your loss unless you insure your device for such loss. It is not covered by your warranty.
    If your iPhone, iPod, iPod Touch, or iPad is lost or stolen what do you do? There are things you should have done in advance - before you lost it or it was stolen - and some things to do after the fact. Here are some suggestions:
    This link, Re: Help! I misplaced / lost my iPhone 5 today morning in delta Chelsea hotel downtown an I am not able to track it. Please help!, has some good advice regarding your options when your iDevice is lost or stolen.
      1. Reporting a lost or stolen Apple product
      2. Find my lost iPod Touch
      3. AT&T. Sprint, and Verizon can block stolen phones/tablets
      4. What-To-Do-When-Iphone-Is-Stolen
      5. iCloud- Use Lost Mode
      6. What to do if your iOS device is lost or stolen
      7. 6 Ways to Track and Recover Your Lost/Stolen iPhone
      8. Find My iPhone
      9. Report Stolen iPad | Stolen Lost Found Online
    It pays to be proactive by following the advice on using Find My Phone before you lose your device:
      1. Find My iPhone
      2. Setup your iDevice on iCloud
      3. OS X Lion/Mountain Lion- About Find My Mac
      4. How To Set Up Free Find Your iPhone (Even on Unsupported Devices)

  • I had 41 tabs open in about six groups over the last year and a half and I just close them and exited Firefox. Is there any way to get them back?

    <blockquote>Locking duplicate thread.<br>
    Please continue here: [[/questions/856718]]</blockquote>
    I had 41 tabs open in about six groups over the last year and a half and I just close them and exited Firefox. Is there any way to get them back?
    Also, is there any way to save a group or an open session and then restore it later?

    History menu, if it was destroyed in the last session
    then use "Restore Previous session:" and then restore all windows also from the history menu.
    If done in this session try the restore all windows under the history menu.

  • My new iphone 5 email is synched with my home office computer Outlook email using a POP account, but deleting an email on my computer does not delete it on my phone and vice versa.  Is there any way to get a true synch?.

    My new iPhone 5 email is synched with my home office computer Outlook email using a POP account, but deleting an email on my computer does not delete the email on my phone and vice versa.  Is there any way to get a true synch?.

    POP does not support synchronization between the server and clients. You will need to use IMAP or Exchange Active Sync if your email provider supports it.

  • I'm having trouble with installing a 8g kit in my late 2009 mac mini. when the parts are installed all i get is a beeping sound, is there any way to get around this?

    i'm having trouble with installing a 8g kit in my late 2009 mac mini. when the parts are installed all i get is a beeping sound, is there any way to get around this?

    What is the source & link to this 8 GB kit please?
    Can you count the beeps or flashes?
    1 beep = no RAM installed
    2 beeps = incompatible RAM types
    3 beeps = no good banks
    4 beeps = no good boot images in the boot ROM (and/or bad sys config block)
    5 beeps = processor is not usable
    In addition to the beeps, on some computers the power LED will flash a corresponding number of times plus one. The LED will repeat the sequence after approximately a 5-second pause. The tones are only played once.
    Note: In this case, a flash is considered to be 1/4 second or 250 ms or greater in length.
    http://support.apple.com/kb/HT1547

  • Update interupted... Any way to get photos off?

    Hi everyone,
    This is my first time posting here so if it's the wrong area, I appologize. I did the latest update this morning for my IPhone (I have an IPhone 3G) from the ITunes store.. I'm not sure of the exact number of the update.
    I was doing the update before work and I ran out of time, so I brought my laptop with me while it was finishing the update.
    As it was toward the end of the update (It had already backed up everything and I guess was putting the new software on), the IPhone came loose from the cord and now all it shows is the ITunes logo and to plug it in. When I do that, it says I have to do a restore to get into ITunes.
    Is there ANY way to get the photos off before I restore to factory settings? I don't care about the contacts or anything but my photos. All my photos of my 1 year old are on there and the last time I backed it up was in September. I know I should have more often and I will do it every month from now on... But any help would be greatly appreciated. I don't care if I even have to go somewhere and pay someone to do it..

    Hi Thank you for getting back to me. This will be a bit lengthy so I appologize to begin with.
    I did not restore the phone before I got back home because I didn't want to take any chances of anything happening with it.
    So I got home and I did the restore and back up at home last night (Clicking on Restore since the IPhone in the device menu didn't have the option to restore from back up).
    After I restored it, it gave me the option to choose a back up to restore to, which I chose the one from yesterday morning.
    It loaded and said on ITunes that the sync or back up was complete and it was safe to remove the IPhone. There was still a bar filling on the Iphone, supposedly loading, still going on the IPhone so I left it connected.
    The bar finally filled, but stayed that way for around 15-20 min without going to the main screen, so I disconnected it. Then it wasn't going away so I shut it off.
    I turned it back on and it started that load bar again with the apple logo above it. It took a long time and I had to go to bed so I let it go. I woke up this morning and it had gone dark so it seemed like it loaded fine. I clicked the circle button and my wall paper came up and everything, I was very happy! I even went to photos and it showed all of them there, very happy!
    The only downfall I saw was all my apps were gone.. Not to worried about that, although if there is a way to get them back, I'd appreciate knowing that also..
    But then I went to the camera and then it said rebuilding library (just so you know I have ALOT of photos on here, over 4500.. No music, just a ton of photos, which I am going to take off tonight hopefully.) So it took forever.. Then it turned off before it finished. I turned it back on and I went to photo's (instead of camera) and it said updating library and the load line is crawling.
    So ever since I first looked at the pictures this morning, I haven't been able to view them again. I tried hooking it up to my laptop during break this morning to start transfering the photos, but it doesn't give me the option to import pictures like it used to (outside of ITunes, as if it were an external hard drive.).
    So that's where I am at... Sorry for the lengthy response, but I figured it would help if you knew everything. At this point I just want to get the pictures off safely and then I don't care if I wipe them off after that.

  • ICloud got deleted off my MacBook Pro. Is there any way to get it back? I have an iphone now and actually have a use for it.

    iCloud got deleted off my MacBook Pro. Is there any way to get it back? I have an iphone now and actually have a use for it.

    Your signature says you have 10.6.8 - is this correct? (It it isn't please amend it to prevent confusion).
    Assuming Snow Leopard, iCloud has not been deleted - it was never there. The minimum requirement for iCloud is Lion 10.7.2 (Mountain Lion preferred): the iCloud Preference Pane does not appear on earlier systems - the MobileMe pane appears on Lion and earlier but is non non-functional - you cannot now open or access a MobileMe account.
    You can set Snow Leopard up to access the email on an existing iCloud account which has been set up on a compliant device, and you may be able to sync iCal using an unsupported (and possibly unreliable) hack, but no other facilities will work. You cannot open an iCloud account on Snow Leopard.
    This page outlines the limited use you can make of an existing iCloud account with Snow Leopard:
    http://www.wilmut.webspace.virginmedia.com/notes/icloudSL.html
    To make full use of iCloud you will have to upgrade your Mac to Lion or Mountain Lion, provided it meets the requirements.
    The requirements for Lion are:
    Mac computer with an Intel Core 2 Duo, Core i3, Core i5, Core i7, or Xeon processor
    2GB of memory
    OS X v10.6.6 or later (v10.6.8 recommended)
    7GB of available space
    To purchase it you will have to ring Apple at the number given at the bottom left of this page.
    The requirements for Mountain Lion are listed here:
    http://www.apple.com/osx/specs/
    It is available from the Mac App Store (in Applications). (If you are currently pre-Snow Leopard you will have to upgrade to that to access the Mac App Store: it's available in the online Apple Store.)
    You should be aware that PPC programs (such as AppleWorks) will not run on Lion or above; and some other applications may not be compatible - there is a useful compatibility checklist at http://roaringapps.com/apps:table

  • The number of active sessions isn't decreasing in OC4J instance

    Hi Guru’s,
    Could you help me, please?
    The number of active sessions isn’t decreasing in OC4J instance after our clients closed the application.
    Our partner use Oracle AS 10gR3 (10.1.3.4.0) with J2EE and HTTP mode.
    When we monitoring our OC4J instance with Performance tab on Oracle EM, we appreciate that the value of Active Sessions on ‘Servlets and JSPs’ are very high. If users close our applications, then number of active sessions isn’t decreasing and active status isn’t becoming inactive.
    Which OC4J settings responsible for managing active sessions and how can I get more information about the active session details?
    Thanks in advance,
    Zoltan

    Dinesh.Rajak wrote:
    When I deployed this code Tomcat, it is giving the output as 0, hence tried with accessing the jsp file in multiple browsers but still it is showing the count of active session as 0 - plz helpPlease, don't resurrect old threads, and it's still the wrong forum. Create a new thread if you have a specific question, and create the thread in the correct forum. I'm closing this thread.
    Kaj

Maybe you are looking for

  • Relation between different objects

    Dear Experts, What is the interlink between Material or acivity to cost-elements, cost components , GL accounts and how does each objects influence costing.

  • AirportExpressON; no network detected

    Airport Express is working with green light but network is gone. It's not even listed as a choice. I've been using it since March and this week I cannot figure out what's happening. I've connected ethernet directly to computer to get online. I'd like

  • Portability of files using third-party Live Effects/filters?

    I'm using Phantasm in my Illustrator file to adjust colors. (http://www.astutegraphics.com/products/phantasm/) I need to send my final files to a production house to get them printed. If they don't have Phantasm on their computers, are my color adjus

  • Difficulty logging into e-mail

    For the last couple of weeks I have had difficulties logging into my e-mails from the bt.com home page. I type in my e-mail address and password, hit log in - and NOTHING happens - the screen just "freezes" without any informaation at the bottom of t

  • 32-bit Linux flash 10.3.181.34 nvidia hardware acceleration chroot

    Hi, I'm trying to run flash in a chroot in a 32-bit debian linux enviroment (the host is also a 32-bit debian system). I'm running the nvidia proprietary drivers and am able to get iceweasel (the debian rebranded firefox) to run flash with hardware a