logic of building a system where laods of people might be on at the same time.

Please support our C# advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Jan 2009
Posts: 12
Reputation: mr.white is an unknown quantity at this point 
Solved Threads: 0
mr.white mr.white is offline Offline
Newbie Poster

logic of building a system where laods of people might be on at the same time.

 
0
  #1
Jan 8th, 2009
Hello,

I'm building a web application which has Users and these Users have permission to access certain bits of the web app.

After a user logs on, according to it's permissions which will be read from permissions table, he will see the bits of the app that he can access.

But to prevent hacking and so on, I need to check if the user has access to that page whenever a page is called on the web server.

If someone goes to for example "a.aspx", I will check from the permissions table if that person has access or not.

But this means there will be a query to PErmissions table each time a page is called.

Will it cause a problem regarding the web app? Will it give errors if more than one query is made at the same time to permissions table?

What is the best way of achieving this goal?

Thank you.
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 2,044
Reputation: Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice 
Solved Threads: 139
Team Colleague
Rashakil Fol's Avatar
Rashakil Fol Rashakil Fol is offline Offline
Super Senior Demiposter

Re: logic of building a system where laods of people might be on at the same time.

 
0
  #2
Jan 8th, 2009
If you have a bunch of processes or threads reading from a table without modifying the table, in a way that affects the others' results, you won't have any problems.
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 12
Reputation: mr.white is an unknown quantity at this point 
Solved Threads: 0
mr.white mr.white is offline Offline
Newbie Poster

Re: logic of building a system where laods of people might be on at the same time.

 
0
  #3
Jan 8th, 2009
Thank you for your fast and clear reply!

I got one more question regarding the issue;
What happens If both users try to change the datas of different rows in the same table at the same time?
Or, what happens if two people try to add new data to the same table at the same time?

Thank you!
Originally Posted by Rashakil Fol View Post
If you have a bunch of processes or threads reading from a table without modifying the table, in a way that affects the others' results, you won't have any problems.
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 2,044
Reputation: Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice 
Solved Threads: 139
Team Colleague
Rashakil Fol's Avatar
Rashakil Fol Rashakil Fol is offline Offline
Super Senior Demiposter

Re: logic of building a system where laods of people might be on at the same time.

 
0
  #4
Jan 9th, 2009
Your database API should have support for transactions; if you put your set of database actions in a transaction, it will see a consistent view of the database -- it will never put the database in some unpredictable state. You should want your transactions to be as short in time duration as possible.
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 12
Reputation: mr.white is an unknown quantity at this point 
Solved Threads: 0
mr.white mr.white is offline Offline
Newbie Poster

Re: logic of building a system where laods of people might be on at the same time.

 
0
  #5
Jan 9th, 2009
Well I'm using .NET and C# and working with an MsSQL 2008 database. Is it OK?

And can you explain where can I make use of DataSet thing of ASP.NET? I don't really understand it.

Thank you!

Originally Posted by Rashakil Fol View Post
Your database API should have support for transactions; if you put your set of database actions in a transaction, it will see a consistent view of the database -- it will never put the database in some unpredictable state. You should want your transactions to be as short in time duration as possible.
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 1,735
Reputation: LizR has a spectacular aura about LizR has a spectacular aura about 
Solved Threads: 186
LizR LizR is offline Offline
Posting Virtuoso

Re: logic of building a system where laods of people might be on at the same time.

 
0
  #6
Jan 9th, 2009
You might want to head over to the ASP.NET forum for your questions about ASP.NET
Did I just hear "You gotta help us, Doc. We've tried nothin' and we're all out of ideas" ? Is this you? Dont let this be you! I will put in as much effort as you seem to.
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Other Threads in the C# Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC