With "bean" do you mean an
EJB (Enterprise
Java Bean) or a regular Java bean?
You should never instantiate EJBs yourself, the EJB container takes care of the lifecycle of EJBs and normally you look them up via JNDI if you need to access them in a servlet.
Regular Java beans are something entirely different; they are just simple Java classes and you can use them as you like in your servlet.
To solve your StackOverflowError, you should look at the stack trace of the error to see where exactly in your code it happens. This kind of error usually happens if you have an endless recursive loop in your program, so you might want to check your code for recursive calls.