I have \"TABLE A\" in database which contains 3 columns \"COL 1\" , \"COL 2\" and \"COL 3\" with around 1000000 (1 Million) records.
\"TABLE A\"
\"COL 1\" , \"COL 2\" and \"COL 3\"
1000000
You have to use Java Caching System(see here) or Ehcache (see here) to store data in cache, Inversion of Control in Spring also helps in some way but not sure whether it would help to store 1 million data in heap, as heap memory is limited.