[JBossCache] - :: Regarding CacheLoaders with Eviction Policies in Place ::
by BhaktavatsalamReddy
Hi,
I am quite new to the JBossCache. We are using JBossCache as the Second Level Cache.
I wanted to know the relation between Eviction Policy and CacheLoader
I have a couple of questions:
What exactly happens when the Eviction Policy is in place withoutthe CacheLoader configuration?
What exactly happens when the Eviction Policy is in place with the CacheLoader configuration?
With the following configuration it has eaten up all of the available virtual memory to the extent, where in it is unable to swap further.
?
| <?xml version="1.0" encoding="UTF-8" ?>
| <server>
| <classpath codebase="./lib" archives="jboss-cache.jar, jgroups.jar" />
|
| <mbean code="org.jboss.cache.TreeCache" name="jboss.cache:service=TreeCache">
| <depends>jboss:service=Naming</depends>
| <depends>jboss:service=TransactionManager</depends>
|
| <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
| <attribute name="NodeLockingScheme">PESSIMISTIC</attribute>
| <attribute name="IsolationLevel">NONE</attribute>
|
| <attribute name="CacheMode">LOCAL</attribute>
|
| <attribute name="UseInterceptorMbeans">false</attribute>
|
| <attribute name="LockAcquisitionTimeout">15000</attribute>
|
| <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
|
| <attribute name="EvictionPolicyConfig">
| <config>
| <attribute name="wakeUpIntervalSeconds">5</attribute>
| <region name="/_default_">
| <attribute name="maxNodes">100</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/CompanyImpl">
| <attribute name="maxNodes">10</attribute>
| <attribute name="timeToLiveSeconds">3600</attribute>
| <attribute name="maxAgeSeconds">3600</attribute>
| </region>
| <region name="/LicenseImpl">
| <attribute name="maxNodes">20</attribute>
| <attribute name="timeToLiveSeconds">3600</attribute>
| <attribute name="maxAgeSeconds">3600</attribute>
| </region>
| <region name="/CompanyImpl.licenses">
| <attribute name="maxNodes">5</attribute>
| <attribute name="timeToLiveSeconds">3600</attribute>
| <attribute name="maxAgeSeconds">3600</attribute>
| </region>
| <region name="/LicenseImpl.accounts">
| <attribute name="maxNodes">100</attribute>
| <attribute name="timeToLiveSeconds">300</attribute>
| <attribute name="maxAgeSeconds">300</attribute>
| </region>
| <region name="/AccountImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">300</attribute>
| <attribute name="maxAgeSeconds">300</attribute>
| </region>
| <region name="/AccountImpl.folderList">
| <attribute name="maxNodes">1</attribute>
| <attribute name="timeToLiveSeconds">300</attribute>
| <attribute name="maxAgeSeconds">300</attribute>
| </region>
| <region name="/AccountAccessPlanImpl">
| <attribute name="maxNodes">10</attribute>
| <attribute name="timeToLiveSeconds">300</attribute>
| <attribute name="maxAgeSeconds">3600</attribute>
| </region>
| <region name="/EncoderImpl">
| <attribute name="maxNodes">50</attribute>
| <attribute name="timeToLiveSeconds">30</attribute>
| <attribute name="maxAgeSeconds">300</attribute>
| </region>
| <region name="/FolderImpl">
| <attribute name="maxNodes">500</attribute>
| <attribute name="timeToLiveSeconds">30</attribute>
| <attribute name="maxAgeSeconds">300</attribute>
| </region>
| <region name="/AssetMasterImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetMasterImpl.assets">
| <attribute name="maxNodes">25</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetMasterImpl.encodingRequestImplList">
| <attribute name="maxNodes">25</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">30</attribute>
| <attribute name="maxAgeSeconds">60</attribute>
| </region>
| <region name="/AccountAttributeImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetMasterAttributeImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetAttributeImpl">
| <attribute name="maxNodes">1000</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AccountImpl.attributeList">
| <attribute name="maxNodes">30</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetMasterImpl.attributeList">
| <attribute name="maxNodes">30</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| <region name="/AssetImpl.attributeList">
| <attribute name="maxNodes">30</attribute>
| <attribute name="timeToLiveSeconds">10</attribute>
| <attribute name="maxAgeSeconds">30</attribute>
| </region>
| </config>
| </attribute>
| <!-- <attribute name="FetchInMemoryState">true</attribute> -->
| <attribute name="CacheLoaderConfiguration">
| <config>
| <passivation>false</passivation>
| <shared>false</shared>
|
| <cacheloader>
| <class>org.jboss.cache.loader.FileCacheLoader</class>
| <properties>
| location=treecache
| </properties>
| <async>false</async>
| <fetchPersistentState>true</fetchPersistentState>
| <ignoreModifications>false</ignoreModifications>
| <purgeOnStartup>true</purgeOnStartup>
| </cacheloader>
| </config>
| </attribute>
| </mbean>
| </server>
|
Please not that passivation is false
Please let know what happens with above config and so that I can configure in the right manner.
Thanks,
Bhakta
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066001#4066001
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066001
18Â years, 9Â months
[Beginners Corner] - Missing database tables (Oracle)
by HibsMax
Hi, Folks.
I posted this in the wrong forum (JBoss Messaging) but Tim informed me to post it in the JBoss AS forum. I couldn't find one with that name so I am trying here.
Peace, Anders
===== original post below =====
Hi, Group.
When I startup my JBoss Server (4.2.0 GA with Messaging 1.3) I find that the following tables are missing from my schema:
HILOSEQUENCES
TIMERS
I believe these tables are supposed to be created at startup.
My colleague did not have this problem with missing tables (we use different schemas / users but the same database instance). Just for a test, I dropped his tables and started my server again. Bingo, my tables are all there. Then he started his server and he started getting the same table or view not found exceptions as I was getting. So, in short, it appears that we cannot start two completely separate JBoss servers using Messaging 1.3 and Oracle with the same database instance (even though we are using separate users). This leads me to believe that when JBoss checks the database for the existence of these tables at startup it casts two wide a net e.g. perhaps the code uses:
select count(*) from all_tables where table_name = 'HILOSEQUENCES'
instead of:
select count(*) from user_tables where table_name = 'HILOSEQUENCES'
Please note, this is just a guess on my part.
I have checked the database users. Neither of them have access to one another's objects via SQL*Plus unless we explicitly prefix each object name with the schema name. In other words, when I am logged in as user1, I cannot see user2's tables and vice versa.
Is this a known limitation / issue? Is there a workaround? I don't believe we should have to use two database instances i.e. one per JBoss.
Thanks, Anders
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4065997#4065997
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4065997
18Â years, 9Â months
[JBoss Seam] - Exception/ Http Error 500 - when doing bad access under /dyn
by henrik.lindberg
By mistake I happened to enter a URL with the part "/dynamic/" inserted before the seam part.
i.e. http://localhost:8080/mysite/dynamic/home.seam instead of
http://localhost:8080/mysite/home.seam
And, I got this exception:
| 00:51:35,218 ERROR [[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
| java.lang.IllegalStateException: No active event context
| at org.jboss.seam.core.Manager.instance(Manager.java:248)
| at org.jboss.seam.servlet.ContextualHttpServletRequest.run(ContextualHttpServletRequest.java:48)
| at org.jboss.seam.web.ContextFilter.doFilter(ContextFilter.java:37)
| at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:68)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:139)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:276)
| at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:60)
| at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:68)
| at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
| at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:68)
| at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:68)
| at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:68)
| at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:149)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:164)
| at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
| at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
| at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:395)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
| at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Thread.java:619)
|
|
If I type any similar URL but with something that does not exists (i.e. foo.seam), I get a 404 instead - which I would have expected on the first as well.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4065994#4065994
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4065994
18Â years, 9Â months
[JBoss Seam] - java.lang.LinkageError
by tony.herstellï¼ gmail.com
Any ideas why I would be getting this?
Caused by: java.lang.LinkageError: loader constraint violation: when resolving method "javax.faces.context.FacesContext.getELContext()Ljavax/el/ELContext;" the class loader (instance of org/jboss/web/tomcat/service/WebAppClassLoader) of the current class, com/sun/facelets/el/ELAdaptor, and the class loader (instance of org/jboss/mx/loading/UnifiedClassLoader3) for resolved class, javax/faces/context/FacesContext, have different Class objects for the type javax/el/ELContext used in the signature
at com.sun.facelets.el.ELAdaptor.getELContext(ELAdaptor.java:45)
at com.sun.facelets.impl.DefaultFaceletContext.(DefaultFaceletContext.java:86)
at com.sun.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:91)
at org.jboss.seam.debug.jsf.SeamDebugPhaseListener.beforePhase(SeamDebugPhaseListener.java:46)
at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:222)
at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
... 33 more
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4065993#4065993
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4065993
18Â years, 9Â months