[JBossCache] - Re: statistics not refreshing
by JerryGauth
If you see the CacheMgmtInterceptor mbean in your JBoss JMX Console display, then UseInterceptorMbeans is definitely enabled.
The main TreeCache mbean (e.g., service=TreeCacheXX) and the CacheMgmtInterceptor mbean both have attributes named "Number of Nodes" and "Number of Attributes." Are these entries non-zero and correct in both mbeans? The CacheMgmtInterceptor mbean obtains this information directly from the TreeCache mbean so the values should be identical.
I added the JBossCache 1.4SP1 jar to my JBossAS 4.0.4GA server and found that the tomcat cache instance did successfully display statistics. I just used the cache's mbean to add and retrieve some nodes; the statistics mbean displayed the expected results.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979124#3979124
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979124
19 years, 8 months
[JBoss Seam] - NPE in Seam conversation code
by andrew.rw.robinson
Seam version 1.0.1
I just had an NPE in my site. The page almost always works, so this is hard to reproduce. The use case is this:
Web page with a conversation that has two IFRAME references. These IFRAMES contain the same JSF page URL but two difference parameters of what to load.
Using the @RequestParameter, I load the data for each IFRAME. This IFRAME JSF page is backed by a CONVERSATION state bean. That way the parent page, and each IFRAME all have different instances of the backing bean and don't collide.
Here is the exception:
java.lang.NullPointerException
| at org.jboss.seam.core.Manager.touchConversationStack(Manager.java:181)
| at org.jboss.seam.core.Manager.storeConversation(Manager.java:368)
| at org.jboss.seam.jsf.AbstractSeamPhaseListener.storeAnyConversationContext(AbstractSeamPhaseListener.java:69)
| at org.jboss.seam.jsf.SeamStateManager.saveSerializedView(SeamStateManager.java:45)
| at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:471)
| at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)
| ...
This happened when I loaded the page for the first time. The error was in the 2nd IFRAME (page page and first IFRAME loaded fine).
When I reloaded the page, both IFRAMEs loaded fine. The page is loaded via RequestParameters and does not depend on any state when it first loads, so that shouldn't be an issue.
The XHTML code snippet looks like:
<iframe src="#{osu:getActionUrl(
| '/pages/liveReport/viewReportInFrame.xhtml')}?reportName=#{
| value.itemInfo.item.name}&appSet=#{webPageView.appSet}"
| style="width: 100%; height: 100%; border-width: 0px;">
| </iframe>
|
Any ideas on why it failed the one time?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979119#3979119
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979119
19 years, 8 months
[EJB 3.0] - Foreign key reference with cascading delete
by jbr
Hi all,
I'm trying to model a foreign key reference with cascading delete. I have the Classes User, List and ListEntry. ListEnry belongs to an instance of List and references an Instance of User. User does not know anything about ListEntry.
I want to make sure, that when a User is deleted, all referencing ListEntries will be deleted too. The Other way round, deleting a ListEntry should not have any affect on the referenced User or List.
In classic ER-Modeling I would have used something like this:
create Table user(String id, String name, ...)
create Table ListEntry(
String id,
String user references user.id on delete cascade,
String list references List.id on delete cascade)
create Table List(String id, String name)
Everything would be perfect in this ER world. With EJB3 i would expect to use the following:
@Entity
| class User{
|
| @Id
| String id
|
| String name
|
| }
|
|
| @Entity
| class ListEntry{
|
| @Id
| String id
|
| User user
|
| @ManyToOne(cascade=CascadeType.REMOVE)
| User getUser(){
| ..}
|
| void setUser(User user){
| }
|
| }
|
| @Entity
| class List{
| @Id
| String id
|
| List<ListEntry> entries;
|
| @OneToMany(cascade=CascadeType.ALL)
| List<ListEntry> getEntries(){
| ...
| }
|
| void setEntries(List<ListEntry> entries){
| ...
| }
|
| }
|
I tried this but it didn't work quite as I expected. Deleting a ListEntry results in a delete of the Referenced User too...
How would I model the above Problem? I'm puzzled.
Thanks for advice
Juergen
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979117#3979117
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979117
19 years, 8 months