Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

What are the disadvantages of placing resultset in session? if not which is the best possible way.I tried to place it in a List<Map<String,String>>,does it not affect the performance?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
134 views
Welcome To Ask or Share your Answers For Others

1 Answer

A ResultSet represents an open connection to the database; generally you want to get your data out and return the connection to the pool as quickly as possible. Storing a ResultSet in the session leaves open the possibility that the connection won't be closed for a long time, which could exhaust the pool, or unnecessarily tie up your database resources.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...