[jboss-cvs] JBossAS SVN: r98926 - trunk/server/src/main/java/org/jboss/ejb.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Dec 23 21:30:29 EST 2009
Author: jason.greene at jboss.com
Date: 2009-12-23 21:30:28 -0500 (Wed, 23 Dec 2009)
New Revision: 98926
Added:
trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainerMBean.java
Modified:
trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainer.java
Log:
Merge 90280
Modified: trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainer.java
===================================================================
--- trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainer.java 2009-12-24 02:18:45 UTC (rev 98925)
+++ trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainer.java 2009-12-24 02:30:28 UTC (rev 98926)
@@ -38,6 +38,7 @@
import javax.ejb.Handle;
import javax.management.ObjectName;
+import org.jboss.ejb.plugins.StatefulSessionInstanceCache;
import org.jboss.invocation.Invocation;
import org.jboss.invocation.InvocationType;
import org.jboss.security.SimplePrincipal;
@@ -57,7 +58,7 @@
public class StatefulSessionContainer
extends SessionContainer
- implements EJBProxyFactoryContainer, InstancePoolContainer
+ implements EJBProxyFactoryContainer, InstancePoolContainer, StatefulSessionContainerMBean
{
/**
* This is the persistence manager for this container
@@ -82,6 +83,14 @@
return instanceCache;
}
+ public long getPassivatedCount()
+ {
+ if (! (instanceCache instanceof StatefulSessionInstanceCache))
+ throw new UnsupportedOperationException();
+
+ return ((StatefulSessionInstanceCache)instanceCache).getPassivatedCount();
+ }
+
public StatefulSessionPersistenceManager getPersistenceManager()
{
return persistenceManager;
Added: trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainerMBean.java
===================================================================
--- trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainerMBean.java (rev 0)
+++ trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainerMBean.java 2009-12-24 02:30:28 UTC (rev 98926)
@@ -0,0 +1,34 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb;
+
+public interface StatefulSessionContainerMBean extends ContainerMBean
+{
+
+ /**
+ * Get the number of instances in this container that are currently passivated.
+ *
+ * @return the number of passivated instances
+ */
+ public long getPassivatedCount();
+
+}
Property changes on: trunk/server/src/main/java/org/jboss/ejb/StatefulSessionContainerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
More information about the jboss-cvs-commits
mailing list