I would like to know how to control the jackson deserialization of a lazy loaded entity. For example, my setup contains two entities
Country 1------many State and
State many----1 Country
Now when I load the country and serialize into JSON, it goes into and infinite recursion between fetching a country's states and the state's country and so on and then errors out.
I would like to stop at fetching at one level only. Say for country stop just at state(or just its id attribute) and need not fetch its country. How can I do this?
Thanks.