• 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

Design problem with Session

 
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi everybody :
i am workin in a system . Let me give u an example . there is a student and a admin . they have different level of access to them system . A student can take the test . A admin can delete edit or add student record. Okay .
So when a student logs is details are taken from the database and stored in the session as UserBean . When the studend is takin the exam how can not allow the Admin not to delete the student from the database???
is there anything i can do like Can i add a the Users who log in in a different Bean of scope Application . If this is a good way then how can i add the Bean in Application scope in a Servlet
pls help me here
i am stuck
Thank you
Siva
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Storing the student data in both the session and the database, where the database may be modified by the instructor sounds like a recipe for disaster. In my courseware, there is only one copy of the student data and it has synchronized access. Both the student and instructor Threads access the same copy of the data - every now and then this copy is backed up to a disk file.
Bill

------------------
author of:
 
Hey, check out my mega multi devastator cannon. It's wicked. It makes this tiny ad look weak:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic