• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Tomcat 8 always login wrong (first) user after logout

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have Tomcat 8 login against my mysql database. Here is how it looks: NetBeans Tomcat Jsp mysql forms login and session

The problem is that when I logout like this:


it logsout but when I try to log in with a different user, it logs in the previous(first) user!

If I restart Tomcat server, I can login with any user at first but any other retry to login with a different but first user is failure: it auto logs in the first user that was logged in.
 
Saloon Keeper
Posts: 27762
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Se Koan wrote:I have Tomcat 8 login against my mysql database. Here is how it looks: NetBeans Tomcat Jsp mysql forms login and session



NetBeans is not part of a J2EE web application. If it makes a difference that you're running NetBeans, you're doing something wrong.

Se Koan wrote:
The problem is that when I logout like this:


it logsout but when I try to log in with a different user, it logs in the previous(first) user!

If I restart Tomcat server, I can login with any user at first but any other retry to login with a different but first user is failure: it auto logs in the first user that was logged in.



Please do not discard Exceptions without analyzing or reporting them. You don't know what valuable/essential information you may be throwing away.

If you are using the JEE-standard security system, it will not log you in automatically under any user ID whatsoever.
 
Fire me boy! Cool, soothing, shameless self promotion:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic