Also, frankflysky java, you may want to change your name to abide by the JavaRanch Naming Policy before you attract the attention of a bartender!
as the container will call appropriate methods on the session attributes implementing the HttpSessionActivationListener on migration...
so conclusion is HttpSessionBindingListener & HttpSessionActivationListener
should'nt be declared in the DD.
I can understand the confusion regarding these two, especially if you read HF, because on page 182 it is vague as to whether or not HttpSessionActivationListener is implemented as its own listener class (like HttpSessionAttributeListener is) or implemented as an attribute class (like HttpSessionBindingListener is). My understand is that it is implemented as its own listener class, and therefore must be declared in the DD. I welcome comments from anyone who is more familiar with the interface, or perhapse had the time to write some test code.
You do NOT configure session binding listeners in the DD! If an attribute class (like the Dog class here) implements the HttpSessionBindingListener, the Container calls the event handling callbacks (valueBound() and valueUnbound()) when an instance of this class is added to or removed from a session. That's it. It just works. But this is NOT true for the other session related listeners on the previous page. HttpSessionListener, HttoSessionAttributeListener, and HttpSessionActivationListener must be registered inthe DD, since they're related to the session itself, rather than an individual attribute placed in the session.
please refer the link Listener in DD
So just so we are straight, HttpSessionBindingListener and HttpSessionActivationListener are both implemented as attribtues, and DO NOT need to be declared in the DD.
I appreciate the correction.