Hello.
I think I might have found a memory leak in my code.
I have an autocomplete text field (using Ajax) to search for persons stored in the database. When the user is searching a person he types in a text
string, i.e,. the first letter in the persons name. The ajax script is calling a
servlet, which returns users from the database. The servlet makes a concatenated string which is returned to the ajax script.
One client has more than 10000 persons stored in the database. After searching a user you submit to another page. Sometimes I have experienced that the next page is showing the long concatenated string of persons that was created in the servlet. It' seems that the buffer is full. Why is the next page showing the concatenated string being created in the servlet from the previous page?
I guess the buffer size may be to large, taken all the memory when few users use the autocomplete field?!
I haven' t found out if I can clear the buffer somehow and if I can set the
JSP buffer size to a fixed value. Maybe there is another problem in my code?
I have attached the servlet code which is returning the concatenated string of persons from the database.
I hope you can help me to see, if I have any memory leaks in the way I make my code.
I appreciate your help.