[EJB 3.0] - Re: JBoss 5 deployment error
by jhsingle
Yes, that's the jar.
$ jar tf workflow-ejb-2.7.0.jar
| META-INF/
| META-INF/MANIFEST.MF
| workflow/
| workflow/ejb/
| workflow/ejb/client/
| workflow/ejb/client/count/
| workflow/ejb/client/model/
| workflow/ejb/server/
| workflow/ejb/server/count/
| workflow/ejb/server/model/
| workflow/ejb/util/
| bootstrap.properties
| META-INF/jboss.xml
| META-INF/persistence.xml
| TC-1025_bpmnxpdl_24.xsd
| workflow/ejb/client/count/Count.class
| workflow/ejb/client/count/CountManagerEndpoint.class
| workflow/ejb/client/count/CountManagerRemote.class
| workflow/ejb/client/EntryParams.class
| workflow/ejb/client/ExecutionDetail$1.class
| workflow/ejb/client/ExecutionDetail.class
| workflow/ejb/client/ExecutionSummary$1.class
| workflow/ejb/client/ExecutionSummary.class
| workflow/ejb/client/model/ModelManagerEndpoint.class
| workflow/ejb/client/model/ModelManagerRemote.class
| workflow/ejb/client/ProcessDefinition.class
| workflow/ejb/client/ProcessDefinitionDigester.class
| workflow/ejb/client/ResultingParams.class
| workflow/ejb/client/StateDefinition$1.class
| workflow/ejb/client/StateDefinition.class
| workflow/ejb/client/StepDefinition$1.class
| workflow/ejb/client/StepDefinition.class
| workflow/ejb/client/TransitionDefinition$1.class
| workflow/ejb/client/TransitionDefinition.class
| workflow/ejb/client/TransitionReference$1.class
| workflow/ejb/client/TransitionReference.class
| workflow/ejb/client/WorkflowEngineLocal.class
| workflow/ejb/client/WorkflowManagerEndpoint.class
| workflow/ejb/client/WorkflowManagerRemote.class
| workflow/ejb/client/WorkflowPackage.class
| workflow/ejb/client/WorkflowParameter.class
| workflow/ejb/server/count/CountManager.class
| workflow/ejb/server/LongRunningAlgorithm.class
| workflow/ejb/server/model/ModelManager.class
| workflow/ejb/server/WorkflowEngine.class
| workflow/ejb/server/WorkflowManager.class
| workflow/ejb/server/WorkflowMDB.class
| workflow/ejb/server/WorkflowUtil.class
| workflow/ejb/util/ActivityDigester.class
| workflow/ejb/util/AlgorithmHandler.class
| workflow/ejb/util/ApplicationException.class
| workflow/ejb/util/ParamUtil.class
| workflow/ejb/util/TransitionDigester.class
| workflow/ejb/util/TransRefDigester.class
| workflow/ejb/util/TransRestrictionDigester.class
| workflow/ejb/util/XPDLUtil.class
| META-INF/ejb-jar.xml
| META-INF/maven/
| META-INF/maven/blackbook-workflow/
| META-INF/maven/blackbook-workflow/workflow-ejb/
| META-INF/maven/blackbook-workflow/workflow-ejb/pom.xml
| META-INF/maven/blackbook-workflow/workflow-ejb/pom.properties
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4199038#4199038
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4199038
15 years, 12 months
[JBoss Cache: Core Edition] - Problem when using EJB3EntityTreeCache for caching entities
by mihai.ratiu
Hi,
I'm new to Jboss Cache and I'm trying to use Jboss Cache 1.4.0SP11 "Cayenne" to cache some of my entities.
I'm using for my application jboss-4.0.5-GA version of the server, in configuration all. The application is using ejb3 entities and I need to reduce the amounts of DB calls to some tables by using the jboss level 2 cache.
I already install EJB3 RC9 Patch 1 for my server configuration, and configured the ejb3-entity-cache-service.xml as following:
<?xml version="1.0" encoding="UTF-8"?>
<!-- ==================================================================== -->
<!-- Defines TreeCache configuration -->
<!-- ==================================================================== -->
jboss:service=Naming
jboss:service=TransactionManager
<!--depends>jboss.j2ee:ear=syncml-connector.ear,jar=syncml.jar,name=SyncMLConnectorDataService,service=EJB3</depends-->
<!-- uncomment next three statements if using JGroups multiplexer,
requires JGroups 2.3 or later, JBossCache 1.4 or later -->
<!--
jgroups.mux:name=Multiplexer
jgroups.mux:name=Multiplexer
fc-fast-minimalthreads
-->
<!-- Configure the TransactionManager -->
org.jboss.cache.JBossTransactionManagerLookup
<!--
Node locking level : SERIALIZABLE
REPEATABLE_READ (default)
READ_COMMITTED
READ_UNCOMMITTED
NONE
-->
REPEATABLE_READ
<!-- Valid modes are LOCAL
REPL_ASYNC
REPL_SYNC
-->
LOCAL
<!-- Name of cluster. Needs to be the same for all clusters, in order
to find each other -->
EJB3-entity-cache
<!-- Must be true if any entity deployment uses a scoped classloader -->
true
<!-- Must match the value of "UseRegionBasedMarshalling" -->
true
OPTIMISTIC
<!-- UDP: if you have a multihomed machine,
set the bind_addr attribute to the appropriate NIC IP address
-->
<!-- UDP: On Windows machines, because of the media sense feature
being broken with multicast (even after disabling media sense)
set the loopback attribute to true
-->
<UDP mcast_addr="${jboss.partition.udpGroup:228.1.2.3}" mcast_port="43333" ip_ttl="${jgroups.mcast.ip_ttl:2}" ip_mcast="true"
mcast_send_buf_size="150000" mcast_recv_buf_size="80000" ucast_send_buf_size="150000"
ucast_recv_buf_size="80000" loopback="false" />
<PING timeout="2000" num_initial_members="3" up_thread="false" down_thread="false" />
<MERGE2 min_interval="10000" max_interval="20000" />
<FD_SOCK down_thread="false" up_thread="false"/>
<FD shun="true" up_thread="false" down_thread="false"
timeout="20000" max_tries="5"/>
<VERIFY_SUSPECT timeout="1500" up_thread="false" down_thread="false" />
<pbcast.NAKACK gc_lag="50" max_xmit_size="8192" retransmit_timeout="600,1200,2400,4800" up_thread="false"
down_thread="false" />
<UNICAST timeout="600,1200,2400" window_size="100" min_threshold="10" down_thread="false" />
<pbcast.STABLE desired_avg_gossip="20000" up_thread="false" down_thread="false" />
<FRAG frag_size="8192" down_thread="false" up_thread="false" />
<pbcast.GMS join_timeout="5000" join_retry_timeout="2000" shun="true" print_local_addr="true" />
<pbcast.STATE_TRANSFER up_thread="false" down_thread="false" />
<!-- The max amount of time (in milliseconds) we wait until the
initial state (ie. the contents of the cache) are retrieved from
existing members in a clustered environment
-->
5000
<!-- Number of milliseconds to wait until all responses for a
synchronous call have been received.
-->
10000
<!-- Max number of milliseconds to wait for a lock acquisition -->
15000
<!-- Name of the eviction policy class. -->
org.jboss.cache.eviction.LRUPolicy
<!-- Specific eviction policy configurations. This is LRU -->
5 -->
<!-- Cache wide default -->
10000
86400
The entities needed to cache were annotated this way:
@Entity(name = "DataStoresConnEntity")
@Table(name = "DATASTORES", uniqueConstraints = {})
@Cache(usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@NamedQueries(...)
public class DataStoresConnEntity implements Serializable
{
....
@OneToMany(mappedBy = "dataStoresEntity", fetch = FetchType.LAZY)
@Cache(usage = CacheConcurrencyStrategy.TRANSACTIONAL)
public Collection getPendingDataStoresEntities()
{
return pendingDataStoresEntities;
}
....
}
and
@Entity(name = "PendingDataStoresConnEntity")
@Table(name = "PENDINGDATASTORES")
@Cache(usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@NamedQueries(...)
public class PendingDataStoresConnEntity implements Serializable
{
...
@ManyToOne(targetEntity = DataStoresConnEntity.class)
@JoinColumn(name = "DATASTOREID", referencedColumnName = "DATASTOREID")
public DataStoresConnEntity getDataStoresEntity()
{
return dataStoresEntity;
}
...
}
We decided that the named queries doesn't need to be cached only the ejb3 entities.
The problem is that after some processing, when the processing stops, the entities are evicted from the cache very fast , after few seconds(~10s). I tried also to set up wakeUpIntervalSeconds to a large number and also tried a setup for "maxAgeSeconds" to 0.
Even if I remove the evictionPolicy the behavior is still the same.
Does anybody have an idea why this strange behavior is happening?
Since the new year is coming soon I wish you a Happy New Year!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4199028#4199028
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4199028
15 years, 12 months