若要啟用個別 SFSB 的可用性並選取進行檢查點操作方法,請使用 sun-ejb-jar.xml 部署.
若要啟用高可用性階段作業持續性,請在 ejb 元素中設定 availability-enabled="true"。若要控制 SFSB 快取的大小和運作方式,請使用以下元素:
max-cache-size:指定快取中保留的階段作業 Bean 的最大數。如果快取溢出 (Bean 的個數超出 max-cache-size),則容器會鈍化一些 Bean 或將 Bean 的串列化狀態寫入檔案。用於建立檔案的目錄來自使用配置 API 的 EJB 容器。
resize-quantity
cache-idle-timeout-in-seconds
removal-timeout-in-seconds
victim-selection-policy
如需有關 sun-ejb-jar.xml 的更多資訊,請參閱「Sun Java System Application Server 9.1 Application Deployment Guide」中的「The sun-ejb-jar.xml File」。
<sun-ejb-jar> ... <enterprise-beans> ... <ejb availability-enabled="true"> <ejb-name>MySFSB</ejb-name> </ejb> ... </enterprise-beans> </sun-ejb-jar>