• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

size that a hashmap can grow

 
subu ananthram
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I have a little confusion am hoping if any of you can shed some light
In the urly bird assignment I start off by populating into a hashmap the record number of each row and its value contained in a string[].Now my question is how big can this hashmap grow? i.e if the flat file grows in size by say ppl inserting records how big will the hashmap be.Also at a certain time the jvm will start kicking off entries in the hashmap.so when i start finding by a criteria it wont be sufficient to rely on this hashmap I will still need to go to the flat file at times?
Can anyone shed some light on how they have implemented the findByCriteria
Cheers
Subu
 
Ernesto Elias-Nieland
Ranch Hand
Posts: 53
Eclipse IDE Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Subu,

You don't have to worry to much about memory constraints if your requirements don't say so. In a real life application you would possibly implement some kind of lazy loading or use a framework that takes care of this for you. In our case just load all record into memory and don't bother.

Cheers,
Ernie
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic