I am porting my application from sun app server to jboss AS 7.1(EAP 6.0) server.
I don't want to remove my SFSB instance from the cache even after it become inactive, for this in my previous application deployment descriptor i used remove-timeout-seconds element in bean cache configuration. where I set value of 0, that specifies that the container does not remove inactive beans automatically.
Is there any element is there in JBOSS AS 7.1 to configure that.
EJB version i am using : 2.1
Thanks in Advance..
Try to use stateful-timeout tagg in your ejb-jar.xml.
And define the timeout to -1 how it's described in spec http://docs.oracle.com/javaee/6/api/javax/ejb/StatefulTimeout.html.
In case that you run your app on AS7 then you should not have any problem to use ejb-jar_3_1.xsd. The specification of EJB 3.1 covers the specification of 2.1 beans as well.
I suppose that you'll be able to use stateful-timeout tag in your app and the 2.1 beans will be working fine.
You can try to check: https://github.com/jbossas/jboss-as/blob/4ccc9d2fb45ef9234e9ced600394f739fd4d8ba9/testsuite/integration/basic/src/test/java/org/jboss/as/test/integration/ejb/descriptor/ejb-jar.xml.
Or maybe you could try to put the timeout definition to jboss-ejb3.xml file whether you don't wan't to change your ejb-jar.xml file.