-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: access big table (>10 million rows)
PostPosted: Mon Apr 04, 2005 2:45 am 
Newbie

Joined: Mon Apr 04, 2005 2:30 am
Posts: 1
Hello,

Hibernate version:
3.0

I am building a messaging web app for 3000 users to
exchange messages with each other (the only way they can send/read messages is through our web app. No open protocol). It is
pretty much like a web mail app - registered users can log in and send to/read messages from each other. We are trying to use Hibernate 3.0 in this project.

There are a lot of historic messages for each user: each user have more than 5000 messages. Even after the system delivered, they will use the system very frequently. So my concern is about the performance/scalability issue:

If we keep all the messages in one table (using userID to distinguish), we'll have a table with >10 million rows. If we keep the messages in seperate tables (one table per user), we'll have 2000 tables with 5000 rows for each.

From DB design point of view, one table is easier to manage. But my concern is, will the performance be hit badly if I use one big table? You know, whenever a user login and access his/her Inbox, the system has to
load first page of messages from that 10-million-row table. Even we put index on userId, will it be performant?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 04, 2005 4:10 am 
Expert
Expert

Joined: Fri Nov 07, 2003 4:24 am
Posts: 315
Location: Cape Town, South Africa
Your performance concerns are more a function of the design of **YOUR** system and the performance/scalability of your database. You are going to face the same issues using straight JDBC or any other data access method.
Of course hibernate may be able to mitigate some of these issues at an application level.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.